4 ms·
The Emacs setup steps are somewhat behind the times. These days it's easier to use packages to install new modes and themes, and Technomancy's Emacs Starter Kit
by weavejester 15y ago
The Emacs setup steps are somewhat behind the times. These days it's easier to use packages to install new modes and themes, and Technomancy's Emacs Starter Kit should be mentioned for those who are new to Emacs and want sensible defaults.
It's even easier with Emacs 24, as the starter kit can be installed via a package as well. Current best practise is to put all the packages you need in your init.el file, then when you start Emacs, it'll download and install any packages you're missing.
You have a section "Other Libraries" and a section "Finding the Libraries You Want", which cover essentially the same ground, but are strangely split up. So the former mentions the Clojure wiki page, and the latter mentions clojure-toolbox and other third-party library lists. Maybe they should all be in one section?
Other things... "lein deps" isn't really necessary anymore, as Leiningen checks for dependencies before running each command.
I think you also need to mention that you can effectively forgo the group-id and have [foo "1.0"] (which is the same as [foo/foo "1.0"]).
Pushing to Clojars is easier with the "lein-clojars" plugin. Then it's just a "lein push" away.
- technomancy 15y agoI've been trying to keep people from learning Emacs and Clojure at the same time since in most cases it just leads to frustration. When you're learning a new language, your editor is never a bottleneck, so it makes a lot more sense to wait till you're comfortable in the language with your current environment before changing editors. Anyway, it's kind of orthogonal to learning Clojure, so it seems a bit out of place here. Perhaps a second article would make more sense, though contributing to the official documentation would of course be much better.
- uvtc 15y agoHi weavejester. Thanks for the feedback! Regarding Emacs, yes, I guess I'm a bit behind the cutting edge. I'll probably revisit the section of the Guide once I make the upgrade to Emacs 24. Meantime though, I don't think the instructions are too onerous, and --- as I mention at the top --- if you've already got a favorite editor, you safely skip the whole section. Re. the "Other Libraries" vs. "Finding the Libraries you Want", thanks for pointing that out. I removed some duplicated info and feels better now. Re. `lein deps`, it could've been clearer, so I made it so. Thanks. Re. group-id, thanks for pointing that out. I'll get that clarified soon. Re. lein-clojars, I like the instructions as is, because I think it will give new users a more concrete feel of what's going on when they upload packages to Clojars.
- ludwigvan 15y ago>> Current best practise is to put all the packages you need in your init.el file, then when you start Emacs, it'll download and install any packages you're missing. I wasn't aware of that, how does that work? Obviously just `require`'ing the packages is not sufficient.
- weavejester 15y agoTake a look at the Emacs Starter Kit README: https://github.com/technomancy/emacs-starter-kit https://github.com/technomancy/emacs-starter-kit Basically it uses a combination of `package-installed-p` to check if the package is installed, and `package-install` to install said package if it is not. Note this is for Emacs 24, which comes with `package.el` preinstalled.
- fingerprinter 15y agoAre there any latest and greatest getting started with Clojure on Emacs guides anywhere? The thing I find most frustrating about using Emacs and Clojure is that the setup is awfully hard. Something simple would be awesome.
- weavejester 15y agoWhat OS do you use?