summaryrefslogtreecommitdiff
path: root/lisp/shell.el
diff options
context:
space:
mode:
authorRichard M. Stallman <rms@gnu.org>1994-09-18 20:28:23 +0000
committerRichard M. Stallman <rms@gnu.org>1994-09-18 20:28:23 +0000
commit1bf41783e491b51a2e4c2c25be40e4af983122c0 (patch)
tree137ab50c4f8689384da95f59a2ab3bf194cbf454 /lisp/shell.el
parent47d6ef91f1a9fcf9cf1c9c0c09850e4f30a74bb1 (diff)
downloademacs-1bf41783e491b51a2e4c2c25be40e4af983122c0.tar.gz
(shell-mode-map): Inherit comint-mode-map, but copy the completion menu.
Diffstat (limited to 'lisp/shell.el')
-rw-r--r--lisp/shell.el4
1 files changed, 3 insertions, 1 deletions
diff --git a/lisp/shell.el b/lisp/shell.el
index 3a502634312..98c3b48fc69 100644
--- a/lisp/shell.el
+++ b/lisp/shell.el
@@ -252,12 +252,14 @@ Thus, this does not include the shell's current directory.")
(defvar shell-mode-map nil)
(cond ((not shell-mode-map)
- (setq shell-mode-map (copy-keymap comint-mode-map))
+ (setq shell-mode-map (nconc (make-sparse-keymap) comint-mode-map))
(define-key shell-mode-map "\C-c\C-f" 'shell-forward-command)
(define-key shell-mode-map "\C-c\C-b" 'shell-backward-command)
(define-key shell-mode-map "\t" 'comint-dynamic-complete)
(define-key shell-mode-map "\M-?"
'comint-dynamic-list-filename-completions)
+ (define-key shell-mode-map [menu-bar completion]
+ (copy-keymap (lookup-key comint-mode-map [menu-bar completion])))
(define-key-after (lookup-key shell-mode-map [menu-bar completion])
[complete-env-variable] '("Complete Env. Variable Name" .
shell-dynamic-complete-environment-variable)