diff options
author | Richard M. Stallman <rms@gnu.org> | 1993-08-08 07:47:33 +0000 |
---|---|---|
committer | Richard M. Stallman <rms@gnu.org> | 1993-08-08 07:47:33 +0000 |
commit | aa00b92d69780daa3c36eed99ce3f7e2bc33379c (patch) | |
tree | cebbb2aebb354865928eaa6fe054d0262a49f8fb /lisp | |
parent | 6f5d1a4f5200f5f68801fa4637cd79df30f95a08 (diff) | |
download | emacs-aa00b92d69780daa3c36eed99ce3f7e2bc33379c.tar.gz emacs-aa00b92d69780daa3c36eed99ce3f7e2bc33379c.tar.bz2 emacs-aa00b92d69780daa3c36eed99ce3f7e2bc33379c.zip |
(shell-command, shell-command-on-region):
Fix bugs in previous change.
Diffstat (limited to 'lisp')
-rw-r--r-- | lisp/simple.el | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/lisp/simple.el b/lisp/simple.el index e3e6a7cebe1..a0ae2f3eeaa 100644 --- a/lisp/simple.el +++ b/lisp/simple.el @@ -630,9 +630,6 @@ then call `undo-more' one or more times to undo them." (error "No further undo information")) (setq pending-undo-list (primitive-undo count pending-undo-list))) -(defvar last-shell-command "") -(defvar last-shell-command-on-region "") - (defvar shell-command-history nil "History list for some commands that read shell commands.") @@ -643,8 +640,9 @@ If COMMAND ends in ampersand, execute it asynchronously. Optional second arg non-nil (prefix arg, if interactive) means insert output in current buffer after point (leave mark after it). This cannot be done asynchronously." - (interactive (list (read-string "Shell command: " last-shell-command) - current-prefix-arg nil nil 'shell-command-history)) + (interactive (list (read-from-minibuffer "Shell command: " + nil nil nil 'shell-command-history) + current-prefix-arg)) (if flag (progn (barf-if-buffer-read-only) (push-mark) @@ -738,9 +736,8 @@ even though that buffer is not automatically displayed. If there is no output or output is inserted in the current buffer then `*Shell Command Output*' is deleted." (interactive (list (region-beginning) (region-end) - (read-string "Shell command on region: " - last-shell-command-on-region - nil nil 'shell-command-history) + (read-from-minibuffer "Shell command on region: " + nil nil nil 'shell-command-history) current-prefix-arg (prefix-numeric-value current-prefix-arg))) (if flag |