I use eclipse to develop,and I use eclipse to export it to runnable jar like this:
and I get a test.jar. I use "java -jar test -service gui GUIService" to run it in cmd.Then I get this problem:
but I can run it in eclipse smoothly,
and my dir is that:
and what should I do?then I can get a runnable jar
Hello and Welcome Maiff
Hello and Welcome Maiff !
Cool font ! ;)
Make a jar is easy .. find build.xml, press F11 and it will build you a jar.
Thanks for the pictures ...
Hopefully, this one will help you.
Build locally
I didn't know about that. Thanks :)
To make it work in my installation, I also had to install git
https://git-scm.com/
And I also had to set the JAVA_HOME envronment variable to make the build find the SDK.
https://www.mkyong.com/java/how-to-set-java_home-on-windows-10/
BUILD SUCCESFUL
That's great becasue now I can test on my RasPi without having to push untested changes.
I should have asked how to do that long time ago :)
Thanks Maiff for asking this question, and thanks GroG for a very good answer :-)
Build from the command line...
If you want to build it the same way that TravisCI builds it.
Dowload "Apache Ant" (I use version 1.8.2.)
https://ant.apache.org/bindownload.cgi
Unzip it, and add the the directory to your PATH environment variable (so you can find it easy on the command line.)
Change into the myrobotlab directory and run the following:
ant clean dist
that should produce a myrobotlab.jar file for you if everything compiles properly and the unit tests pass.
Thanks Kevin
I tried it and it works fine. The build hosting seems to be on a powerful machine. The build when I push a change takes about 4-5 minutes. On my old laptop about 30 minutes .....