Re: What is the best replacement for running scripts using groovy-all?

2018-12-20 Thread Mario Garcia
BTW about @Grab, bear in mind that you can tell @Grab where to put/take its dependencies from: groovy -Dgrape.root=./lib my_script.groovy So every project can have its dependencies in the project's structure. Regards Mario El jue., 20 dic. 2018 a las 10:44, Paul Moore () escribió: > I can

Re: What is the best replacement for running scripts using groovy-all?

2018-12-20 Thread Paul Moore
I can understand that logic - there are quirks I've hit with the fat jar approach, but because I made the fat jar myself, I'm OK with just assuming it's a weirdness that I can either live with or investigate. But if it happened with a supplied jar, I'd feel that I should report the problem (even

Re: What is the best replacement for running scripts using groovy-all?

2018-12-19 Thread Paul King
We don't want to publish a fat jar to maven because it will cause problems that we will continually be asked about but perhaps having an uber jar within the zip distribution might be something we could look at. I suspect over time though that even that could be problematic. On Thu, Dec 20, 2018

Re: What is the best replacement for running scripts using groovy-all?

2018-12-19 Thread Remko Popma
You may be interested in the Gradle application plugin. This creates a distribution zip file with all the dependencies and some starter scripts. https://docs.gradle.org/current/userguide/application_plugin.html The only customization would be to add your custom script to the bin/ directory

Re: What is the best replacement for running scripts using groovy-all?

2018-12-19 Thread Paul Moore
On Wed, 19 Dec 2018 at 22:46, MG wrote: > > Hi, > > out of curiosity (and because having a fat jar again might be > conventient at some point in the future in my work environment (also no > internet access)): > > This solution proposed by Keith does not work >

Re: What is the best replacement for running scripts using groovy-all?

2018-12-19 Thread MG
Hi, out of curiosity (and because having a fat jar again might be conventient at some point in the future in my work environment (also no internet access)): This solution proposed by Keith does not work https://github.com/gradle/gradle-groovy-all ? Cheers, mg Am 19.12.2018 um 23:33

Re: What is the best replacement for running scripts using groovy-all?

2018-12-19 Thread Paul Moore
On Wed, 19 Dec 2018 at 22:33, Paul Moore wrote: > Something simple like > > task customFatJar(type: Jar) { > dependsOn copyDeps > baseName = 'all-in-one-jar' > from "dest/lib" > } > > gives me an "all-in-one-jar.jar" that contains the dependency jars > directly included, rather than

Re: What is the best replacement for running scripts using groovy-all?

2018-12-19 Thread Paul Moore
On Wed, 19 Dec 2018 at 21:23, James Kleeh wrote: > > Paul, > > The best solution is to use Maven or Gradle to create an all-in-one (fat) jar > that you can ship and run with java -jar > > Gradle has a shadow plugin and Maven has a shade plugin to do just that. Thanks. I'd come to the conclusion

Re: What is the best replacement for running scripts using groovy-all?

2018-12-19 Thread Nelson, Erick
Grab caches it files by default in your user home directory in .groovy/grapes Just zip up that dir and copy it to the server you want it on, and extract it. Sent from my iPhone > On Dec 19, 2018, at 1:24 PM, James Kleeh wrote: > > Paul, > > The best solution is to use Maven or Gradle to

Re: What is the best replacement for running scripts using groovy-all?

2018-12-19 Thread James Kleeh
Paul, The best solution is to use Maven or Gradle to create an all-in-one (fat) jar that you can ship and run with java -jar Gradle has a shadow plugin and Maven has a shade plugin to do just that. James > On Dec 19, 2018, at 4:19 PM, Paul Moore wrote: > > On Wed, 19 Dec 2018 at 20:18,

Re: What is the best replacement for running scripts using groovy-all?

2018-12-19 Thread Paul Moore
On Wed, 19 Dec 2018 at 20:18, Søren Berg Glasius wrote: > > Hi Paul, > > This is where The @Grab anotation comes in handy: > http://docs.groovy-lang.org/latest/html/documentation/grape.html > > It wil automatically download your dependencies and it works in Groovy > scripts too. Thanks - yes,

Re: What is the best replacement for running scripts using groovy-all?

2018-12-19 Thread Søren Berg Glasius
Hi Paul, This is where The @Grab anotation comes in handy: http://docs.groovy-lang.org/latest/html/documentation/grape.html It wil automatically download your dependencies and it works in Groovy scripts too. Best regards / Med venlig hilsen, Søren Berg Glasius Hedevej 1, Gl. Rye, 8680 Ry,

Re: What is the best replacement for running scripts using groovy-all?

2018-12-19 Thread Paul Moore
On Wed, 19 Dec 2018 at 08:56, Paul Moore wrote: > > On Wed, 19 Dec 2018 at 00:03, Keith Suderman wrote: > > > > Option 4) Use the Maven Assembly plugin or the Shade plugin to build your > > own groovy-all Jar file. Or just use > > https://github.com/gradle/gradle-groovy-all > > Thanks. Are

Re: What is the best replacement for running scripts using groovy-all?

2018-12-18 Thread Keith Suderman
Option 4) Use the Maven Assembly plugin or the Shade plugin to build your own groovy-all Jar file. Or just use https://github.com/gradle/gradle-groovy-all - Keith > On Dec 17, 2018, at 3:49 AM, Paul Moore > wrote: >