talios / clojure-maven-plugin

Apache Maven Mojo for compiling clojure scripts to class files
251 stars 74 forks source link

add support for nrepl-handler (e.g. cider-nrepl) #87

Closed andeee closed 8 years ago

andeee commented 10 years ago

I wanted to use cider-nrepl with clojure-maven-plugin, so I added support for handler in the nrepl mojo. To use it with cider-nrepl just configure nreplHandler or the property clojure.nrepl.handler to cider.nrepl/cider-nrepl-handler and add cider-nrepl to the projects dependencies.

buildhive commented 10 years ago

Mark Derricutt » clojure-maven-plugin #65 SUCCESS This pull request looks good (what's this?)

tomjack commented 10 years ago

:+1:

I currently put a hacky replScript in my projects as a workaround:

(require 'clojure.tools.nrepl.server 'cider.nrepl)

(alter-var-root #'clojure.tools.nrepl.server/default-middlewares
                into
                (map resolve cider.nrepl/cider-middleware))
jstaffans commented 8 years ago

Have you also been successful in connecting to the nREPL from CIDER, or are you just using the features from the cider.nrepl middleware? CIDER 0.12.0 does not seem to find anything to connect to.

mvn clojure:nrepl -Dclojure.nrepl.handler=cider.nrepl/cider-nrepl-handler 

Might it be that this only works for some older version of CIDER?