jacamo-lang / jacamo

This project aims to promote the MultiAgent Oriented Programming (MAOP) approach by providing a suitable integration of tools and languages for programming agents, their environment and organisation.
https://jacamo-lang.github.io
GNU Lesser General Public License v3.0
77 stars 32 forks source link

[Question] How to deploy a runnable JAR? #11

Closed lcpz closed 7 years ago

lcpz commented 7 years ago

This might be a trivial question, still I'm not able to figure it out.

Could you please tell me the exact steps to do in order to create a runnable, self-contained JAR?

For instance, assume you have the hello-world example project. How do you create a JAR that you can launch just with java -jar ... and get "hello world" printed? Thanks in advance.

jomifred commented 7 years ago

Hi Luke,

this is a feature available in Jason that wasn't implemented in JaCaMo yet. I will try to do that soon.

lcpz commented 7 years ago

Thank you.

Actually, I found this. It works, but the autogenerated xml does not include a jar option.

jomifred commented 7 years ago

Hi, I've just changed jason/moise/jacamo to support the creation of single jars for jacamo applications, as it exits for Jason. Since a lot of files were changed, I produced a new release for jacamo at

https://sourceforge.net/projects/jacamo/files/version-0

with all files. Some documentation for the new scripts at https://github.com/jacamo-lang/jacamo/blob/master/doc/tutorials/hello-world/shell-based.adoc. The jason like command

ant -f bin/yourmas.xml jar

also works.

Of course, github sources were also updated.

lcpz commented 7 years ago

Thanks.