Function: cider-load-file
cider-load-file is an interactive and byte-compiled function defined
in cider-eval.el.
Signature
(cider-load-file FILENAME &optional UNDEF-ALL)
Documentation
Load (eval) the Clojure file FILENAME in nREPL.
If the file is a cljc file, and both a Clojure and ClojureScript REPL
exists for the project, it is evaluated in both REPLs. The heavy lifting
is done by cider-load-buffer.
When UNDEF-ALL is non-nil or called with C-u (universal-argument), removes
all ns aliases and var mappings from the namespace before reloading it.
Key Bindings
Aliases
Source Code
;; Defined in ~/.emacs.d/elpa/cider-20260414.1619/cider-eval.el
(defun cider-load-file (filename &optional undef-all)
"Load (eval) the Clojure file FILENAME in nREPL.
If the file is a cljc file, and both a Clojure and ClojureScript REPL
exists for the project, it is evaluated in both REPLs. The heavy lifting
is done by `cider-load-buffer'.
When UNDEF-ALL is non-nil or called with \\[universal-argument], removes
all ns aliases and var mappings from the namespace before reloading it."
(interactive (list
(read-file-name "Load file: " nil nil nil
(when (buffer-file-name)
(file-name-nondirectory
(buffer-file-name))))
(equal current-prefix-arg '(4))))
(if-let* ((buffer (find-buffer-visiting filename)))
(cider-load-buffer buffer nil undef-all)
(cider-load-buffer (find-file-noselect filename) nil undef-all)))