For a long time I’ve wanted a simple, double-clickable executable for Incanter, and now thanks to Alan Dipert’s swingrepl library I have it.
I have made an executable jar file, called incanter.jar, that launches a swingrepl, that includes Incanter and all of its dependencies, when double-clicked or started with the following command
java -jar incanter.jar
Note: Make sure to save incanter.jar with the .jar extension to ensure it executes correctly.
I have also used Apple’s Jar Bundler and SkoobySoft’s DMG Packager to create a Mac OS X executable that’s downloadable as a dmg file, Incanter.dmg.
Finally, I used Launch4j to create the Windows executable file,
Incanter.exe.
To build incanter.jar from source, use script/package
in the Incanter distribution on Github, or just use lein uberjar
(lein will call the file incanter-standalone.jar, and will create a non-executable jar called incanter.jar).
Excellent! Next step is to get core to do the same thing. ;-)
Agreed, and thats as easy as removing Incanter from the mix, but I’d also like to see a version with more libraries included, instead of less. For instance do this to labrepl (which may be getting a new name, ClojureLab).
That’s awesome! Downloading it *right* now!
This is great. However, the group-by function is not working, even for the examples in the documentation. It is giving a java.lang.IllegalArgumentException: Don’t know how to create ISeq from: java.lang.Integer (NO_SOURCE_FILE:0)
error.
Do you mean incanter.core/$group-by or clojure.core/group-by? Can you provide the example that isn’t working?
Probably the fastest way I can get people to try out Clojure, thanks :). Looking forward to swingrepl getting completion support
Cool, but what to do when there’s no X?
Do you mean X11? If so, just run a command line repl with:
java -cp incanter.jar clojure.main
Oh! Thanks a lot for the quick reply.
(I’m new to both clojure and incanter.)