Function: eshell--set-option
eshell--set-option is a byte-compiled function defined in
esh-opt.el.gz.
Signature
(eshell--set-option NAME AI OPT OPTIONS OPT-VALS)
Documentation
Using NAME's remaining args (index AI), set the OPT within OPTIONS.
If the option consumes an argument for its value, the argument list will be modified.
Source Code
;; Defined in /usr/src/emacs/lisp/eshell/esh-opt.el.gz
(defun eshell--set-option (name ai opt options opt-vals)
"Using NAME's remaining args (index AI), set the OPT within OPTIONS.
If the option consumes an argument for its value, the argument list
will be modified."
(if (not (nth 3 opt))
(eshell-show-usage name options)
(setcdr (assq (nth 3 opt) opt-vals)
(if (eq (nth 2 opt) t)
(if (> ai (length eshell--args))
(error "%s: missing option argument" name)
(pop (nthcdr ai eshell--args)))
(or (nth 2 opt) t)))))