Function: cider-jack-in-clj&cljs
cider-jack-in-clj&cljs is an autoloaded, interactive and byte-compiled
function defined in cider.el.
Signature
(cider-jack-in-clj&cljs &optional PARAMS SOFT-CLJS-START)
Documentation
Start an nREPL server and connect with clj and cljs REPLs.
PARAMS is a plist optionally containing :project-dir, :jack-in-cmd and
:cljs-repl-type (e.g. shadow, node, figwheel, etc).
With the prefix argument, allow for editing of the jack in command; with a double prefix prompt for all these parameters.
When SOFT-CLJS-START is non-nil, start cljs REPL only when the ClojureScript dependencies are met.
Key Bindings
Source Code
;; Defined in ~/.emacs.d/elpa/cider-20260414.1619/cider.el
;;;###autoload
(defun cider-jack-in-clj&cljs (&optional params soft-cljs-start)
"Start an nREPL server and connect with clj and cljs REPLs.
PARAMS is a plist optionally containing :project-dir, :jack-in-cmd and
:cljs-repl-type (e.g. `shadow', `node', `figwheel', etc).
With the prefix argument, allow for editing of the jack in command;
with a double prefix prompt for all these parameters.
When SOFT-CLJS-START is non-nil, start cljs REPL
only when the ClojureScript dependencies are met."
(interactive "P")
(let ((cider-jack-in-dependencies (append cider-jack-in-dependencies cider-jack-in-cljs-dependencies))
(cider-jack-in-lein-plugins (append cider-jack-in-lein-plugins cider-jack-in-cljs-lein-plugins))
(cider-jack-in-nrepl-middlewares (append cider-jack-in-nrepl-middlewares cider-jack-in-cljs-nrepl-middlewares))
(orig-buffer (current-buffer)))
;; cider--update-jack-in-cmd relies indirectly on the above dynamic vars
(let ((params (thread-first params
(cider--update-project-dir)
(cider--check-existing-session)
(cider--update-jack-in-cmd)
(cider--update-cljs-type)
;; already asked, don't ask on sibling connect
(plist-put :do-prompt nil))))
(nrepl-start-server-process
(plist-get params :project-dir)
(plist-get params :jack-in-cmd)
(lambda (server-buffer)
(with-current-buffer orig-buffer
(let ((clj-repl (cider-connect-sibling-clj params server-buffer)))
(if soft-cljs-start
(when (cider--check-cljs (plist-get params :cljs-repl-type) 'no-error)
(cider-connect-sibling-cljs params clj-repl))
(cider-connect-sibling-cljs params clj-repl)))))))))