This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-06-08
Channels
- # asami (15)
- # babashka (123)
- # beginners (174)
- # calva (4)
- # cider (6)
- # cljdoc (4)
- # cljs-dev (4)
- # cljsrn (18)
- # clojure (268)
- # clojure-australia (1)
- # clojure-europe (107)
- # clojure-ireland (5)
- # clojure-nl (2)
- # clojure-uk (18)
- # clojured (1)
- # clojurescript (21)
- # conjure (4)
- # cursive (38)
- # data-science (1)
- # datahike (6)
- # datomic (4)
- # events (1)
- # fulcro (9)
- # graalvm (16)
- # helix (6)
- # honeysql (4)
- # instaparse (3)
- # jobs (1)
- # observability (15)
- # pathom (7)
- # pedestal (15)
- # polylith (9)
- # practicalli (1)
- # re-frame (6)
- # remote-jobs (2)
- # specter (7)
- # sql (16)
- # tools-deps (1)
- # vim (5)
- # xtdb (1)
FWIW, a tool like jenv, whose intended use-case is to switch which JVM you're using from the command-line, not only sets $JAVA_HOME but also modifies $PATH to put the correct java
binary first. It sounds like you were already using exec-path-from-shell
to make emacs inherit the environment you configure for the shell. I wonder if whatever jenv was doing to modify $PATH was incompatible with something in cider
(like, maybe there's a jenv directory on the $PATH with symlinks to actual java binaries on it?)
I've experimented with this myself on Debian because I didn't want to "switch" the global default JVM statefully using e.g. sudo update-java-alternatives -s adoptopenjdk-8-hotspot-amd64
and I discovered that I can launch a Clojure subprocess with any of the installed JVM versions, giving the same effect as update-java-alternatives
but isolated to one process AOT a global stateful "default"
all I had to do to execute that Clojure subprocess with a particular JVM version was setting $PATH and $JAVA_HOME
thanks for the jenv info, yeah I am macOS but not quite a master of emacs, so when the shell in emacs and cider seem to do something differently I don't really know where to go, also tried digging through the cider source a bit but couldn't get any wiser. Oh well, it works without jenv anyway.