Move shell-related menu items to "Shell Commands" submenu (bug#37594)
* lisp/menu-bar.el (menu-bar-shell-commands-menu): New variable. (menu-bar-tools-menu): Move shell-related menu items to 'menu-bar-shell-commands-menu' and add menu items for 'async-shell-command' and 'shell'.
This commit is contained in:
parent
2be48605c0
commit
55803cc189
1 changed files with 26 additions and 7 deletions
|
@ -1649,6 +1649,27 @@ mail status in mode line"))
|
||||||
|
|
||||||
menu))
|
menu))
|
||||||
|
|
||||||
|
(defvar menu-bar-shell-commands-menu
|
||||||
|
(let ((menu (make-sparse-keymap "Shell Commands")))
|
||||||
|
(bindings--define-key menu [interactive-shell]
|
||||||
|
'(menu-item "Run Shell Interactively" shell
|
||||||
|
:help "Run a subshell interactively"))
|
||||||
|
|
||||||
|
(bindings--define-key menu [async-shell-command]
|
||||||
|
'(menu-item "Async Shell Command..." async-shell-command
|
||||||
|
:help "Invoke a shell command asynchronously in background"))
|
||||||
|
|
||||||
|
(bindings--define-key menu [shell-on-region]
|
||||||
|
'(menu-item "Shell Command on Region..." shell-command-on-region
|
||||||
|
:enable mark-active
|
||||||
|
:help "Pass marked region to a shell command"))
|
||||||
|
|
||||||
|
(bindings--define-key menu [shell]
|
||||||
|
'(menu-item "Shell Command..." shell-command
|
||||||
|
:help "Invoke a shell command and catch its output"))
|
||||||
|
|
||||||
|
menu))
|
||||||
|
|
||||||
(defun menu-bar-read-mail ()
|
(defun menu-bar-read-mail ()
|
||||||
"Read mail using `read-mail-command'."
|
"Read mail using `read-mail-command'."
|
||||||
(interactive)
|
(interactive)
|
||||||
|
@ -1740,16 +1761,14 @@ mail status in mode line"))
|
||||||
(bindings--define-key menu [gdb]
|
(bindings--define-key menu [gdb]
|
||||||
'(menu-item "Debugger (GDB)..." gdb
|
'(menu-item "Debugger (GDB)..." gdb
|
||||||
:help "Debug a program from within Emacs with GDB"))
|
:help "Debug a program from within Emacs with GDB"))
|
||||||
(bindings--define-key menu [shell-on-region]
|
|
||||||
'(menu-item "Shell Command on Region..." shell-command-on-region
|
|
||||||
:enable mark-active
|
|
||||||
:help "Pass marked region to a shell command"))
|
|
||||||
(bindings--define-key menu [shell]
|
|
||||||
'(menu-item "Shell Command..." shell-command
|
|
||||||
:help "Invoke a shell command and catch its output"))
|
|
||||||
(bindings--define-key menu [compile]
|
(bindings--define-key menu [compile]
|
||||||
'(menu-item "Compile..." compile
|
'(menu-item "Compile..." compile
|
||||||
:help "Invoke compiler or Make, view compilation errors"))
|
:help "Invoke compiler or Make, view compilation errors"))
|
||||||
|
|
||||||
|
(bindings--define-key menu [shell-commands]
|
||||||
|
`(menu-item "Shell Commands"
|
||||||
|
,menu-bar-shell-commands-menu))
|
||||||
|
|
||||||
(bindings--define-key menu [rgrep]
|
(bindings--define-key menu [rgrep]
|
||||||
'(menu-item "Recursive Grep..." rgrep
|
'(menu-item "Recursive Grep..." rgrep
|
||||||
:help "Interactively ask for parameters and search recursively"))
|
:help "Interactively ask for parameters and search recursively"))
|
||||||
|
|
Loading…
Add table
Reference in a new issue