On Thursday, March 17, 2016 at 12:10:21 PM UTC-5, blake watson wrote:
>
> On Sat, Mar 12, 2016 at 2:42 PM, Lee Spector <lspe...@hampshire.edu 
> <javascript:>> wrote:
>
> > Is "lein new app foo" that complicated?
>
> If I understand Paul correctly—and am not just imposing my own similar 
> feelings on him—the problem is not that "lein new app foo" is complicated, 
> it's that it creates a directory structure that is complicated for the 
> beginner. Clojure is by far not the worst in this regard, but a new app 
> creates seven folders (root, doc, resources, src, test, src/root and 
> test/root) and nine files (.gitignore, .hgignore, CHANGELOG.md, LICENSE, 
> project.clj, README.md, intro.md, core.clj and core_test.clj). This is a 
> lot for someone just trying to grasp "Hello, world."
>
> The less you have to say to the student ("you can ignore all that for 
> now") the better. The less you have to tell the user to toggle mysterious 
> switches (as with the JVM stack options) the better.
>
>

Partly this, yes.  And partly also that there's a lot of semi-documented 
magic behind the scenes.  For example: leiningen has "new" and "new app." 
The tutorial says that they're different, and that one is appropriate for 
applications and the other for libraries, but doesn't offer any clue why, 
or what the differences might be---and it's hard to see, even coming from 
other languages, why there might be a reason for the difference. Is it 
something about namespacing and some kind of "main" path through the code 
for applications?  That's just my guess... 

Or the classpath.  Apparently this is a JVM thing, and leiningen hides it 
from the user, but sometimes it breaks, and then it's kind of a guessing 
game why unless one knows Java.  

And it doesn't help that it also makes unintuitive default decisions for 
one sometimes.  For example, I actually just spend several hours last night 
beating my head against the REPL's refusal to let me use core.matrix in a 
library I'm working on---it took a SO post plus some good luck to learn 
that core.matrix requires clojure 1.7+, and then notice that for some 
mysterious reason the version of leiningen I didn't install all that long 
ago defaulted to 1.6.   (The REPL, of course, didn't actually throw an 
error that gave any hint that there were version problems; the dependency 
just silently failed, and then when I tried to use the namespace that 
required core.matrix, it just threw an incomprehensible error claiming that 
it couldn't find the file --- see 
http://stackoverflow.com/questions/36051140/clojure-classpath-troubles-loading-code-and-dependencies-with-leiningen/36052171#36052171
 
--- that's just unfriendly behavior.)

Don't get me wrong. I'm not complaining. The more I learn about leiningen, 
the more I like it---the power to just swap out language versions 
altogether by changing one line in a config file, for example, is 
wonderful---and makes a lovely contrast with, for example, the Python 2/3 
craziness. But the fact that there's a ton of machinery going on behind the 
scenes to actually get anything running, even with good tools that abstract 
it away (when they work right), makes the ecosystem less beginner-friendly, 
because when something goes wrong it's a beast to figure out why. 

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to