Why? There are several reasons:
.elfiles in my
.lisp.ddirectory, and almost half of them are outdated.
So basically, the author customized his emacs with a lot of add-ons, especially to assist coding activity: auto-complete, snippets, connection to various REPLs, etc. I wanted to do the same, but without using the complete overtone configuration files. That’s almost done!
Be sure to grab one of the 24.* series in the build repository. I personally choose the 24.1-rc pretest version. I haven’t had any problem so far.
To configure ELPA, we can add the following two lines in our
(setq package-archives '(("marmalade" . "http://marmalade-repo.org/packages/") ("tromey" . "http://tromey.com/elpa/")))
This will add Marmalade as well as Tromey ELPA to the default GNU repository. Something that’s really important is to configure the keyboard; in order to exchange command the option (⌥) and command (⌘) keys, I just added
(setq mac-option-modifier 'none)
Otherwise, we cannot type symbols like
~ (Alt-n), or use square brackets (which is pretty sad when writing R code :-). Other customizations can be added, for example to make the connection with Mac
pbpaste more transparent.
I am also trying to familiarize myself with ido-mode that I’ve never used:
(require 'ido) (ido-mode t)
My first impressions were disconcerting, but now I seem to get used to it. I just have to remember that I now have to C-d to get into
dired-mode for browsing content of a directory.
.emacs is not entirely clean at the moment: I need to investigate the autoload vs. require issue more carefully. For the moment, I am quite happy with the configuration of Lisp, Clojure, R, and Python. I can connect to Slime using either
lein swank or
M-x clojure-jack-in from within Emacs. For R, I have Yasnippets working right out of the box, together with other goodies from ESS. I was previously using the Stata ado-mode, but
ess-mode provides most of the basic functionalities I need for interacting with Stata.
An example of an interactive R session is shown below:
Top panel shows how Yasnippet prompting tool is triggered when pressing tab (⇥), while bottom panel shows available arguments when typing
rnorm in the R shell directly.
Here is another screenshot which show the beginning of a clojure script with auto-completion and a running
lein shell (left), and one (right) with two buffers with Yasnippet providing basic construction of a
defn in Clojure (top), or suggesting methods in Python mode (bottom).
Finally, this configuration works equally well when Emacs run in a Terminal (
nw), as can be seen below: