Slide-deck from talk at the f(by) conference in Minsk.
M-x
View Slide
slide intentionallyleft blank
Вітаю!
Bozhidar
Божидар
Божоcool
Bugcool
Sofia, Bulgaria
A (Dark) Knight oftheOrder of Emacs
@bbatsov
Why I am here?
I am a storyteller!
CIDER:Inside The Brewery
A story about a different kindof cider…
ClojureInteractiveDevelopmentEnvironment thatRocks
… for Emacs
Is Emacs the One True Editorthat will bring balance to theSource?
Absolutely!
Primary Clojure devenvironment (2015)Other10%LT5%fireplace12%Cursive27%CIDER46%
–Nancy Pearcey“Competition is always a good thing. Itforces us to do our best. A monopolyrenders people complacent and satisfiedwith mediocrity.”
Near future (optimistic)Other10%CIDER90%
Near future (worst case)Cursive34%Other15%CIDER51%
Customer Testimonials
“Using CIDER is exciting. Younever know if cider-jack-in willwork or not!”— Mich Hickey
I used to wonder a lot how to getan adrenaline rush - now Isimply upgrade CIDER!— Alex Killer
CIDER’s learning curve isamazing! I’m still amazed itnever ends!— Zach Hellman
Half the things in Emacs andCIDER seem magic to me. Everytime I use them I feel like a wizard!— Anna Parenlicka
A not so long time ago in agalaxy not far away…
Java, C# and PHP ruled thedev world
The Lisp Masters from theRepublic of Great Programmerswere on the run
Lisps were out offashion
2007
A gentleman&a scholar
Clojure
Biggest Clojure problem atlaunch?
((((((((((()))))))))))
0Clojuredevelopmentenvironments
Emacs was the last Lispstronghold
Emacs is the greatestEmacs Lispdev environment
SLIME
SuperiorLispInteractionMode forEmacs
SLIME Features• REPL• Interactive evaluation• Compilation notes• Code completion• Definition lookup• Documentation lookup• Apropos
SLIME Features• Debugger• Value inspector• Tracing• Find usages• Macroexpansion• Scratchpad• Minibuffer code evaluation
SLIME is an IDE
Interactive DevelopmentEnvironment
Programs are built in a veryincremental manner
SLIME(Emacs Lisp)SWANK(Common Lisp)ClozureRPCLispWorksCMUCLABCLSBCLClient Server Backends
2008
clojure-mode&swank-clojure
SLIME(Emacs Lisp)SWANK(Common Lisp)swank-clojure
A star was born
In 2010 around 70% of theClojurians were developing inEmacs!!!
swank-clojure• Requires knowledge of swank (Common Lisp)• Bundles a frozen SLIME version• Subpar features (e.g. debugger, inspector, find usages)• Monolithic (no swank plugins)
SLIME is aCommon Lisptool
2010
Another esteemedgentleman&scholar
nREPL
A common foundationfor Clojure development tools
•Load (compile) a Clojure source file•Evaluate a Clojure form•Interrupt evaluation•Read from the standard input
Extensible via middleware
2012
nrepl.el
nrepl.el(Emacs Lisp)nREPL(Clojure)
A workhorse is retired
nrepl.el• lacked many SLIME features• relied heavily on evaluation of inlined code• made assumptions about the environment• flawed bencode parser
2013
Don’t settle for good.Demand great!
–Phil Karlton“There are only two hard things inComputer Science: cache invalidationand naming things.”
ClojureIntegratedDevelopmentEnvironment &REPL
ClojureInteractiveDevelopmentEnvironmentReimagined
CIDER Features• Interactive evaluation• Compilation notes• Code completion• Definition lookup• Documentation lookup• Apropos
CIDER Features• Value inspector• Command selector• Tracing• Macroexpansion• Debugger• Scratchpad• Minibuffer code evalution
CIDER Features• Javadoc support• Jump to Java definition• Jump to resource• Sanity-preserving stacktraces• clojure.test integration• namespace browser
CIDER Features• classpath browser• grimoire integration• dynamic indentation• dynamic font-locking• nREPL session manager• Smart namespace reloading• ClojureScript support
Extensions(are easy)
Refactoring support(clj-refactor + refactor-nrepl)
Demo Time
CIDERtastes better thanSLIME
CIDERtastes better thansome IDES
Bulgarian Liberation Day2016
CIDER 0.11 (Bulgaria)
Require Clojure 1.7+
Require Java 7+
Run all loaded/project tests
Enlighten
Auto-injection of CIDER’sdependencies
Clojure/west 2016
CIDER 0.12 (Seattle)
Conditional breakpoints
Step-in while debugging
Test result improvements
Zenburn & Solarizedsupport
cider-auto-test-mode
Eldoc improvements
Display docstring on mousehover
Totally reorganized menus
One more thing…
A Real Manual
http://cider.readthedocs.org/
CIDER 0.13 (California)
Unified evaluation commandskeymap
C-c C-v something
cider-eval-sexp-at-point
C-c C-v (C-)v
Tracking of evaluatedexpressions
“See also” section in docbuffers
A cornucopia of smalladditions and improvements
CIDER 0.14 (Berlin)
Display spec in doc buffers
Re-run last test
C-c C-t (C-)g
The usual mix of bug fixes, smalladditions and improvements
What’s still missing?
•Find usages•Built-in refactoring tooling•Better ClojureScript support•Support for the new Clojure socketREPLCIDER 1.0
Why CIDER?
Integrated DevelopmentEnvironment (a.k.a. IDE)
Emacs
Spacemacs
Emacs usersknow how to build productiveLisp workflows
•Emacs (ultimate Elisp dev env)•SLIME (and SLY)•Geiser•racket-mode•CIDER (obviously)
• paredit• smartparens• rainbow-delimiters• rainbow-identifiers• sexp-fu• paxedit• lispy
Community impact
cider-nreplhttps://github.com/clojure-emacs/cider-nrepl
refactor-nreplhttps://github.com/clojure-emacs/refactor-nrepl
complimenthttps://github.com/alexander-yakushev/compliment
cljs-toolinghttps://github.com/gtrak/cljs-tooling
nREPL improvements
Open development
158 contributors!
Please, send more help!
Дзякуй!
Felina