Function: cider-set-eval-destination
cider-set-eval-destination is an interactive and byte-compiled
function defined in cider-session.el.
Signature
(cider-set-eval-destination TYPE)
Documentation
Set the current buffer's eval dispatch (REPL type) to TYPE.
TYPE is one of clj, cljs, multi, or auto. All but auto set
cider-repl-type-override for this buffer, overriding the major-mode-based
inference of cider-repl-type-for-buffer so that evaluations target the
chosen REPL of the buffer's session; auto clears the override. The choice
is reflected in the mode line.
This is handy in buffers with no inherent file type to dispatch on (e.g. the
scratch buffer) and in .cljc buffers where you want to pin evaluations to a
specific REPL.
Key Bindings
Source Code
;; Defined in ~/.emacs.d/elpa/cider-20260822.1520/cider-session.el
(defun cider-set-eval-destination (type)
"Set the current buffer's eval dispatch (REPL type) to TYPE.
TYPE is one of `clj', `cljs', `multi', or `auto'. All but `auto' set
`cider-repl-type-override' for this buffer, overriding the major-mode-based
inference of `cider-repl-type-for-buffer' so that evaluations target the
chosen REPL of the buffer's session; `auto' clears the override. The choice
is reflected in the mode line.
This is handy in buffers with no inherent file type to dispatch on (e.g. the
scratch buffer) and in `.cljc' buffers where you want to pin evaluations to a
specific REPL."
(interactive (list (intern (completing-read
"Eval destination: "
(mapcar #'symbol-name cider-eval-destinations)
nil t))))
(setq-local cider-repl-type-override (unless (eq type 'auto) type))
(cider--reflect-eval-destination-in-mode-line)
(message "Buffer eval destination set to `%s'" type))