Add ability to edit vterm command in buffer
This commit is contained in:
parent
373cf299e9
commit
8d695f3998
@ -41,8 +41,14 @@
|
||||
(comint-send-invisible "Enter password: ")
|
||||
(vterm-send-string "\n")
|
||||
(clear-this-command-keys))
|
||||
(defun vterm-edit-zsh-command-line ()
|
||||
"Edit the current command line in a temp buffer."
|
||||
(interactive)
|
||||
(vterm-send-C-x)
|
||||
(vterm-send-C-e))
|
||||
:general
|
||||
(leader-map "v" #'project-vterm)
|
||||
(vterm-mode-map "C-x C-e" #'vterm-edit-zsh-command-line)
|
||||
:custom
|
||||
(vterm-max-scrollback 10000)
|
||||
(vterm-environment '("TYPEWRITTEN_CURSOR=terminal"))
|
||||
|
@ -128,6 +128,11 @@ fi
|
||||
# kubectl completion
|
||||
[[ $commands[kubectl] ]] && source <(kubectl completion zsh)
|
||||
|
||||
# edit the current command line in $EDITOR
|
||||
autoload -U edit-command-line
|
||||
zle -N edit-command-line
|
||||
bindkey '\C-x\C-e' edit-command-line
|
||||
|
||||
# VTerm integration
|
||||
# Some of the most useful features in emacs-libvterm require shell-side
|
||||
# configurations. The main goal of these additional functions is to enable the
|
||||
|
Loading…
Reference in New Issue
Block a user