

I used to use emacs, and I had installed Carbon Emacs to try out org-mode. Getting emacs running and installing packages with ELPA This indicates that the swank server is running, and is ready to be connected to by emacs. The first time you run it, lein deps will show the download and installation progress.) (Note: I made this tutorial while running through these steps for the second time, so lein deps is using files that have already been downloaded. I added a dev-dependencies line to my Leiningen project file. So I tackled getting lein-swank running, and I put off installing SLIME, which I didn’t know how to use, until afterward. The lein-swank plugin is a server, and therefore doesn’t require emacs to be up and running to run. Before I even tried importing incanter, I started working on getting emacs and lein-swank running. When I read the above message, though, I felt like I should give one of the two a try. I haven’t been using emacs, and nailgun doesn’t sound very appealing to me, mainly because when I looked at using it with JRuby a year or two ago, it came with security warnings so strong that they seemed to be telling me you don’t want to use this. I wasn’t planning on using swank or nailgun. I opened project.clj and added the repository and dependency information for Incanter:Īnd then, following the instructions in Leiningen’s README file, I ran lein deps and lein repl in the project directory: Only project.clj will need to be modified to get an Inanter repl environment up and running. This creates a directory called incanterplayground with project.clj and a few other files. To start a new Leiningen project, I went to my home directory and ran: Opening a Clojure repl with access to Leiningen If you replace aquamacs-emacs-starter-kit with emacs-starter-kit, all of the instructions in this blog post should work on other platforms, with some other minor changes. I installed this on Snow Leopard, but these instructions should work on Leopard as well. That’s it! It uses the Java installation that comes with OS X.

I’m going to continue using it to set up repl environments. It was at least as convenient as I expected.

I used Leiningen because I knew it made packages easy to install, and while it is described more often as a build tool than as a package manager, it has a repl command, so I can use it for experimenting with libraries, too. Here are the steps I took: Installing Leiningen A couple of days ago I set out to get it running nicely, and was successful. I’ve known of Incanter, a powerful statistics library for Clojure, for a while now.
