Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p><a href="https://stackoverflow.com/questions/1805081/clojure-cant-find-clj-in-local-directory-and-classes-on-classpath/1935612#1935612">This answer</a> I posted to another question should hopefully give you an idea of how your filenames should relate to namespace names for things to work. However, since your question is "how to set up a simple Clojure project", the following is a better start:</p> <ol> <li><p>Go to GitHub and grab <a href="http://github.com/technomancy/leiningen" rel="nofollow noreferrer">Leiningen</a>.</p></li> <li><p>Follow the instructions in the README. You'll end up doing something like</p> <pre><code>$ lein new my-project $ cd my-project # ... edit project.clj ... $ lein deps </code></pre></li> <li><p>Hack away! You'll need to put your files in the correct places. That will mean putting your source files in the directory tree rooted at <code>my-project/src</code>, with your core namespace most likely residing at <code>my-project/src/my_project/core.clj</code>. But really, I've explained all the details in <a href="http://github.com/technomancy/leiningen" rel="nofollow noreferrer">the answer linked to above</a>, so please read it (and do leave a comment if I missed something). :-)</p></li> </ol> <p>Leiningen will take care of the basic project layout and setting up the classpath for a REPL / swank / nailgun for you (if you haven't yet come across the latter two, you will soon -- but that's a separate topic, the swank part of which I have covered to a certain degree e.g. <a href="https://stackoverflow.com/questions/2285437/a-gentle-tutorial-to-emacs-swank-paredit-for-clojure/2285756#2285756">in this SO answer</a>), so hopefully you'll never need to deal with the <code>java -cp ...</code> nonsense by hand. (The swank-related answer I linked to in the last parenthetical remark has details on how to set up swank with the correct classpath from within Emacs.)</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload