Hi Thomas,

> On 25 Mar 2015, at 10:28, Thomas Driessen <[email protected]> wrote:
> 
> cd C:\ace  (change to the folder of the client.jar)
> java  -Dace.gogo.script=script.foo -jar client.jar (execute client.jar with
> the script "script.foo".)
> 
> - Right now the script only has the following code:
> 
> echo "Hello World"
> 
> exit 0
> […]
> As I already said: --nointeractive leads to an error when I try to execute
> the "exit 0" command. If I don't use --nointeractive within the Jenkins
> build step I get Exceptions like "Framework not running".

To make Gogo shell work in non-interactive mode, you need to do:

$ java -Dace.gogo.script=script.foo -Dgosh.args=--nointeractive -jar client.jar

Furthermore, by default, Gogo does not recognise the ‘exit’ command used to
shutdown the client. To add this, you need to add the following line somewhere
at the beginning of your script:

  addcommand system (((${.context} bundles) 0) loadclass java.lang.System)

after which you can use “exit 0” to terminate the client.

Hope this helps,

--
Met vriendelijke groeten | Kind regards

Jan Willem Janssen | Software Architect
+31 631 765 814

My world is revolving around INAETICS and Amdatu

Luminis Technologies B.V.
Churchillplein 1
7314 BZ   Apeldoorn
+31 88 586 46 00

http://www.luminis-technologies.com
http://www.luminis.eu

KvK (CoC) 09 16 28 93
BTW (VAT) NL8169.78.566.B.01

Attachment: signature.asc
Description: Message signed with OpenPGP using GPGMail

Reply via email to