comparison lisp/eshell/esh-opt.el @ 91015:b83d0dadb2a7

Merge from emacs--devo--0 Patches applied: * emacs--devo--0 (patch 857-865) - Update from CVS - Merge from emacs--rel--22 - Update from CVS: lisp/emacs-lisp/avl-tree.el: New file. - Remove RCS keywords * emacs--rel--22 (patch 97-100) - Update from CVS - Merge from gnus--rel--5.10 * gnus--rel--5.10 (patch 246-247) - Update from CVS Revision: emacs@sv.gnu.org/emacs--unicode--0--patch-252
author Miles Bader <miles@gnu.org>
date Wed, 29 Aug 2007 05:03:40 +0000
parents f55f9811f5d7 4d60bd4e5610
children 53108e6cea98
comparison
equal deleted inserted replaced
91014:2392e6a45952 91015:b83d0dadb2a7
56 BODY-FORMS. If instead an external command is run, the tag 56 BODY-FORMS. If instead an external command is run, the tag
57 `eshell-external' will be thrown with the new process for its value. 57 `eshell-external' will be thrown with the new process for its value.
58 58
59 Lastly, any remaining arguments will be available in a locally 59 Lastly, any remaining arguments will be available in a locally
60 interned variable `args' (created using a `let' form)." 60 interned variable `args' (created using a `let' form)."
61 (declare (debug (form form sexp body)))
61 `(let ((temp-args 62 `(let ((temp-args
62 ,(if (memq ':preserve-args (cadr options)) 63 ,(if (memq ':preserve-args (cadr options))
63 macro-args 64 macro-args
64 (list 'eshell-stringify-list 65 (list 'eshell-stringify-list
65 (list 'eshell-flatten-list macro-args))))) 66 (list 'eshell-flatten-list macro-args)))))
99 last-value (eval (append (list 'progn) 100 last-value (eval (append (list 'progn)
100 body-forms))) 101 body-forms)))
101 nil)) 102 nil))
102 (error "%s" usage-msg)))) 103 (error "%s" usage-msg))))
103 (throw 'eshell-external 104 (throw 'eshell-external
104 (eshell-external-command ext-command args)) 105 (eshell-external-command ext-command args))
105 last-value)) 106 last-value))
106 107
107 (defun eshell-show-usage (name options) 108 (defun eshell-show-usage (name options)
108 "Display the usage message for NAME, using OPTIONS." 109 "Display the usage message for NAME, using OPTIONS."
109 (let ((usage (format "usage: %s %s\n\n" name 110 (let ((usage (format "usage: %s %s\n\n" name