Create a projectλ︎
Create a project called todo-list using Leiningen, the build automation tool for Clojure. This project will run the simplest possible webserver.
On the command line:
Take a look at the project structureλ︎
Change into the todo-list directory created by the Leiningen command and see the project structure that has been created.
project.clj- the project configuration, written in Clojuresrcfor all the source codetestfor unit test code
Using the tree command is a simple way to see the project structure (alternatively use ls -R or a graphical file browser).
Hint:: File names and the Java class pathλ︎
The
srcandtestdirectories both contain a directory namedtodo_listeven though our project istodo-list.Unfortunately the Java classpath does not like dashes '-' in directory or file names, so Leiningen changes the directory names to
src/todo_list&test/todo_listand the initial test tosrc/todo_list/core_test.clj.

