Is there a way to setup REPL to always pprint?
clojure, read-eval-print-loop
Solution
Just use
(clojure.main/repl :print pprint)
Found here.
From the docs:
repl clojure.main
(repl & options) ... - :print, function of one argument, prints its argument to the output default: prn ...
Problem
I found myself wrapping expressions in pprint way too often. Something tells me that there's an option somewhere to do this automatically, but I can't find it. So, instead of typing this: ``` (pprint list-of-maps) ``` I would like to just type ``` list-of-maps ``` in the REPL and get the pretty printed output.