M-x package-install [RET] clojure-mode [RET] M-x package-install [RET] cider [RET]
Now when you open a
.clj file, run
M-x cider-jack-in to connect to a REPL. Alternatively, you can use
C-u M-x (cider-jack-in) to specify the name of a
boot project, without having to visit any file in it. You should now be able to evaluate expressions in your file using
Editing code in lisp-like languages is much more comfortable with a paren-aware editing plugin. Emacs has several good options.
pareditA classic Lisp editing mode that has a steeper learning curve, but provides a lot of power once mastered.
M-x package-install [RET] paredit [RET]
smartparensA newer project with similar goals and usage to
paredit, but also provides reduced capabilities with non-Lisp languages.
M-x package-install [RET] smartparens [RET]
parinferA much simpler Lisp editing mode that operates mainly via inferring proper paren nesting from indentation.
Installation is more involved, see the Github page for
parinfer-modefor setup instructions.
(add-hook 'clojure-mode-hook #'paredit-mode)
(add-hook 'clojure-mode-hook #'smartparens-strict-mode)