greglook / whidbey

nREPL middleware to pretty-print colored values
The Unlicense
158 stars 10 forks source link

Not working with CIDER (again?) #20

Closed neverfox closed 5 years ago

neverfox commented 9 years ago

Here is my profiles.clj:

{:user {:plugins [[cider/cider-nrepl "0.8.1"]
                  [lein-midje "3.1.3"]
                  [mvxcvi/whidbey "1.0.0"]]
        :dependencies [[spyscope "0.1.5"]
                       [org.clojure/tools.nrepl "0.2.10"]
                       [org.clojure/tools.namespace "0.2.10"]
                       [org.clojure/tools.logging "0.3.1"]
                       [io.aviso/pretty "0.1.18"]
                       [alembic "0.3.2"]
                       [im.chit/vinyasa.inject "0.3.4"]
                       [im.chit/vinyasa.reflection "0.3.4"]]
        :injections [(require 'spyscope.core)
                     (require '[vinyasa.inject :as inject])
                     (require 'io.aviso.repl)
                     (require 'io.aviso.logging)

                     (inject/in [vinyasa.inject :refer [inject [in inject-in]]]

                                [alembic.still [distill pull] lein [load-project pull-project]]

                                [clojure.tools.namespace.repl refresh]
                                [clojure.repl doc source]

                                clojure.core
                                [vinyasa.reflection .> .? .* .% .%> .& .>ns .>var]

                                clojure.core >
                                [clojure.java.shell sh]
                                [puget.printer pprint cprint])

                     (io.aviso.repl/install-pretty-exceptions)
                     (io.aviso.logging/install-pretty-logging)
                     (io.aviso.logging/install-uncaught-exception-handler)]
        :whidbey {:print-color true}}}

Everything works in lein repl in the terminal.

greglook commented 9 years ago

My initial guess is that the plugin's profile isn't being loaded. Whidbey adds a :whidbey/repl profile which has metadata with the :repl key set. This causes Leiningen's repl task to merge the profile when starting.

I'm not sure what task CIDR uses to start a REPL, but it may not be merging profiles the same way Leiningen does.

greglook commented 5 years ago

Closing as stale - let me know if this is still an issue, I think some folks have gotten CIDER working with the newer versions.