The reason we use a different extension is because a build.boot file is not semantically a Clojure file.
Clojure's default namespace is 'user'; .boot files run in 'boot.user'. Clojure only automatically refers clojure.core; we refer clojure.core and also boot.core.
So, dependencies notwithstanding, Clojure wouldn't be able to make sense of a build.boot file, and we think the .clj extension would be disingenuous.
We differ in these ways from .clj because one of our goals was to make it easy to create Clojure applications as single scripts.
The downside is users must configure their editors to get syntax highlighting, but we think this is the lesser evil.
The problems you mention seem generic issues others face when using clojure in similar ways. So may be we can convince clojure core developers to add hooks that provide these features without having to introduce new fileextensions each time somebody needs to refer an extra namespace by default.
Just a suggestion. But the current solution seems reasonable until then.
There's some mention of clojure being used as a scripting language here that can be invoked with a shebang - does anybody know if the way this is done is any different (performance-wise) than compiling a leiningen project to an uberjar?
When I've tried using clojure for really simple things, like a "Hello, World" program, and compiled this to a jar to run with something like "java -jar hello.jar," the time it takes to start up the program is pretty abysmal. I'd like to use clojure for something on the Raspberry Pi, but it can take about 30 seconds to run "Hello, World!"
Any secrets to getting it to start up faster, or am I just stuck?
I absolutely refuse to use this because of the inappropriate name of the tool. It is far too general to be anywhere near what I would consider well-named, and seems mostly just a lazy convenience. cloboot would work just as well, and give a user some chance of associating the name of the tool with the purpose of the tool. (I already have a boot.)
When you install the tool you can name it whatever you want. I have qualms about "just download this binary and execute it, trust me" installation methods, but the advantage is you can put it wherever, and name it whatever suits your system.
I recommend naming it 'unicorn-slomp'. Or 'mustash-cash-stash' - but you can pick your own cartoons to make a reference to, you are totally empowered here.
Imperative builds are a different mindset - where lein projects feel like a different language which emulates Clojure syntax, boot feels more like a library, and context switching is a favourite HN bugbear. Being able to program a build can be a boon, where otherwise you might've had to rely on the creator of your build tool catering to your special case with an appropriate flag.
In practice, though, I've never created a project with very interesting builds in either tool, I only dabble in Clojure. The test will ultimately be whether the community finds it useful.
The biggest thing that grabbed me about boot was the scripting capability. To be able to build concise little applications - 'complete', 'real' applications that can be distributed and deployed - is very freeing. The point of the article was to illustrate how you can get running quickly using that feature and logically evolve into "serious" project-based work as needed.
Ultimately there's more to being productive as a beginner than using the REPL.
Is there any specific advantages to using another file extension rather than using `.clj`