Fork me on GitHub

I'm trying to get print_function to work when connected to a babashka repl. In my init.vim I have let g:conjure#client#clojure#nrepl#eval#print_function="user/zprint-pprint". Then I evaluate:

(defn zprint-pprint
  "An nrepl-friendly wrapper."
  ([value writer]
   (zprint-pprint value writer {}))
  ([value writer options]
   (binding [*out* writer]
     (zprint.core/zprint value {}))))

    (create-ns 'user)
    (intern 'user 'zprint-pprint))
This works with my lein and clj-cli setups. Not sure what I'm missing


Maybe BB doesn't support that option :thinking_face:


It's a key I pass along with each eval, if you turn on g:conjure#debug and see the key in the log then there's not much else I can do. I think it'll be a think babashka would have to add support for. Either that or you need to load zprint with require manually before the nREPL server tries to use it?


Gotcha, thanks!