clojure-emacs / cider

The Clojure Interactive Development Environment that Rocks for Emacs
https://cider.mx
GNU General Public License v3.0
3.52k stars 643 forks source link

Support adding -Djdk.attach.allowAttachSelf to jack-in params to enable nrepl JVMTI agent #3693

Closed alexander-yakushev closed 1 month ago

alexander-yakushev commented 1 month ago

Also, add cider-enable-nrepl-jvmti-agent customizable to control this behaviour.

For now, the required Java property is injected for Leiningen and Clojure CLI jack ins. It probably should also do so for gradle and maven?

Additionally, I need advice on where to document this best, and if this can be tested somehow.


bbatsov commented 1 month ago

For now, the required Java property is injected for Leiningen and Clojure CLI jack ins. It probably should also do so for gradle and maven?

Yeah, that would be ideal. This might also be a good time to purge the Boot stuff.

Additionally, I need advice on where to document this best, and if this can be tested somehow.

The documentation can go here I guess - https://docs.cider.mx/cider/usage/code_evaluation.html#configuration

I think there were a few tests checking that the params for Lein and friends were properly generated, so you can add something there.

I'm not sure where's the best place to add this exactly, but your proposal seems reasonable.

alexander-yakushev commented 1 month ago

Added tests, updated docs. Ready for review.