I have turned on (helm-mode 1)
and selectively turned it off for find-file
for default emacs behavior, which I prefer. I would also like to restore non-helm behavior for file completion when invoking shell-command
. E.g. if I do M-! ls ~/<tab>
it currently shows the helm completion buffer. How can I use the default emacs file navigator for shell-command
, while keeping helm globally?
Add a comment
|
1 Answer
Answering my own question, here is to create a wrapper to turn off helm-mode for a specific command:
(defun my-shell-command (&optional no-op)
(interactive)
(let ((completion-in-region-function 'completion--in-region))
(call-interactively 'shell-command)))
(global-set-key "\M-!" 'my-shell-command)