Function: eshell--source-file

eshell--source-file is a byte-compiled function defined in em-script.el.gz.

Signature

(eshell--source-file FILE &optional ARGS SUBCOMMAND-P)

Documentation

Return a Lisp form for executing the Eshell commands in FILE, passing ARGS.

If SUBCOMMAND-P is non-nil, execute this as a subcommand.

Source Code

;; Defined in /usr/src/emacs/lisp/eshell/em-script.el.gz
(defun eshell--source-file (file &optional args subcommand-p)
  "Return a Lisp form for executing the Eshell commands in FILE, passing ARGS.
If SUBCOMMAND-P is non-nil, execute this as a subcommand."
  (let ((cmd (eshell-parse-command `(:file . ,file))))
    (when subcommand-p
      (setq cmd `(eshell-as-subcommand ,cmd)))
    `(let ((eshell-command-name ',file)
           (eshell-command-arguments ',args)
           ;; Don't print subjob messages by default.  Otherwise, if
           ;; this function was called as a subjob, then *all* commands
           ;; in the script would print start/stop messages.
           (eshell-subjob-messages nil))
       ,cmd)))