3 ms·
1. make a new lein project 2. fill in the dependencies in project.clj 3. open your src/core.clj (or whatever) in LT 4. start coding LT will automatically la
by i-blis 13y ago
1. make a new lein project
2. fill in the dependencies in project.clj
3. open your src/core.clj (or whatever) in LT
4. start coding
LT will automatically launch a client and connect to it. In between lein will have seamlessly fetched the dependencies for you (this happens automatically each time you launch or relaunch a client).
You can do manual (C-Enter) or live (Instarepl) inline evaluation in any of your project file or even connect a new fresh repl to the client to experiment from scratch.
- jspiral 13y agoWould you then recommend focusing development around some unit tests and eval-ing them as you do work? (that's what I am trying so far, seems ok)
- i-blis 13y agoPrecisely. This is at least how I do it. It is also pretty nice to have an Instarepl where you can see live changes, either in your source files or in a separate repl. Don't forget that if your paths and namespaces match you can require your namespaces at will.
- xaritas 13y agoI'm normally not a screencasts kind of guy, but is there a good one for using the REPL to assemble, oh, say a web app in Compojure? I started doing a Clojure/Compojure tutorial the other day and I thought I was doing way too much restarting to get changes to take effect (using emacs/nrepl).