This is a great article. More articles in similar tone are needed to highlight how simple this language is. A big disservice to Clojure was probably done by a few early adopters of Clojure who hyped up the LISP heritage of the language to the extent it turned away C/java guys like myself: I recall reading somewhere that in order to learn Clojure , one had to master SICP and Scheme. That was a huge learning curve I did not have time or inclination for. However, once I waded into Clojure, I was amazed by how simple the language is really and how productive I could get; Clojure REPL is awesome . I still haven't mastered the language, I haven't mastered macros, protocols etc. and I bet my code is ghastly and non-idiomatic but I have still managed to write Clojure code that does what it is supposed to do in a highly concurrent workload.
I didn't know about clojure-toolbox. That's pretty neat.<p>One thing though, regarding this page, is that you don't need to install clojure with brew. Leiningen takes care of all that... clojure is just a jar that's included in your project, aka a dependency, and Leiningen manages that. This lets you tie a specific version of clojure to that project, which is handy for some legacy projects that aren't maintained anymore.<p>Also, if you drop the brew references, then this becomes OS agnostic. Just go to the leiningen page on github[1] and it'll get you started: osx, windows, linux.<p>I develop with clojure on my mac and I've not brewed anything related to clojure.<p>[1] <a href="https://github.com/technomancy/leiningen" rel="nofollow">https://github.com/technomancy/leiningen</a>
> The reason that you won’t find yourself running `clj` often is that the REPL built into bare Clojure is pretty much garbage....<p>This is what rlwrap is for. Call `rlwrap clj` instead of `clj`, and you get all that and more (C-r, for reverse incremental search, etc). Works with every other REPL that doesn't bother to re-implement read-line.
I knew about clojars.org, but I hadn't known about <a href="http://www.clojure-toolbox.com/" rel="nofollow">http://www.clojure-toolbox.com/</a>. Very nice!<p>I also recommend the Value of Values video presentation: <a href="http://www.infoq.com/presentations/Value-Values" rel="nofollow">http://www.infoq.com/presentations/Value-Values</a>. It will help you internalize Clojure's approach to data.<p>I really wish I could remember why I didn't experience <i>nearly</i> as much pain starting out as the author, but I'm glad that he took the trouble to put this together.
Very nice, JR, best guide I've seen.<p>I've always wished, though, that all "getting started" guides would just provide a chef recipe or machine image with everything ready to go. Getting to know a language shouldn't require jumping through an hour of hoops and documentation to get it set up.<p>(Of course, the guide here is broader than simply getting your system set up.)
At first the Clojure environment is confusing: why do I need Leiningen? How do I use libraries in my project? This article is a good place to start for beginners, as it explains all that.
I have been thinking about getting into Clojure, but time is precious. It doesn't seem like there are that many jobs out there, but I could be wrong.<p>For those of you in the industry, why would I want to use Clojure? What would be a good project to try it on? A Web app? Why is it worth learning it?
I wish someone would do a Learn Clojure the Hard Way. The comments in this thread is a great documentation of the unfounded fears of the language.<p>I also want to point out to those who are using Windows: Yeah, you could, but this is not a good idea. Leiningen 2 is not available for Windows, but you can still get quite a bit done. At some point, you just have to bite the bullet and install a VM with Linux to really dive into it.
"When I was going through all this myself a few months back, there was a weird period of a good few weeks when I had basically no mental map of the Clojure ecosystem and had no idea how to assemble one."<p>One of the things you can do when learning something new is to hop onto IRC and join a channel related to the topic. I almost always have got a good overview of things just by asking around what I am supposed to know.
I'm interested in learning LISP.
How good a choice is learning Clojure as a way of achieving this?<p>I've read a page[1] listing differences between Clojure and other LISPs, but I'm not sure that I fully understand the implications of these differences.<p>[1] <a href="http://clojure.org/lisps" rel="nofollow">http://clojure.org/lisps</a>
<a href="http://youtu.be/VVd4ow-ZcX0" rel="nofollow">http://youtu.be/VVd4ow-ZcX0</a><p>this video by Chas Emerick (co-author of clojure programming) also gives a good introduction to start with clojure, especially for people who uses eclipse.
The same thing could be done in Python (with requests) and Ruby (with whatever-it-is) with more clarity, less confusion, and <i>much</i> less consumption of resources.)<p><pre><code> (:headers resp)
</code></pre>
This construction is confusing - it breaks environmental model (scoping) <i>and</i> general evaluation rule of Lisps - is :headers a global symbol? a part of foo namespace? Is it macros?<p><pre><code> (resp :headers)
</code></pre>
On the other hand, this form is perfectly consistent - I'm sending to some closure which is bound in a global or other environment a constant message.<p>The assumption that the reader function implicitly transforms first form to second is of no good, because it is not obvious and breaks intuition about environments and violates principle of less astonishment.<p>That thing (:headers resp) returned - what language is it?)