undo + ghostty
This commit is contained in:
@@ -209,6 +209,9 @@ fi
|
||||
# prevent CTRL+S to freeze in vim, CTRL+Q to unfreeze!
|
||||
stty -ixon
|
||||
|
||||
# release CTRL+U to readline processing => undo
|
||||
stty kill undef
|
||||
|
||||
PROMPT_COMMAND='__prompt_command' # Func to gen PS1 after CMDs
|
||||
|
||||
# ALIASES
|
||||
|
||||
+7
-2
@@ -29,15 +29,20 @@ set convert-meta off
|
||||
|
||||
# CTRL + { backspace, delete } for word suppressing
|
||||
"\C-H": backward-kill-word
|
||||
"\e[3;5~": kill-word
|
||||
|
||||
# ALT + { backspace, delete } for suppressing until start/end (faster)
|
||||
# ALT + { backspace, delete } for suppressing until start/end (faster)
|
||||
"\e[3;3~": kill-line
|
||||
"\e\C-?": backward-kill-line
|
||||
|
||||
# ALT + { backspace, delete } for suppressing the whole line
|
||||
# SHIFT + { backspace, delete } for suppressing the whole line
|
||||
"\e[3;2~": kill-whole-line
|
||||
"\e[127;2u": kill-whole-line
|
||||
|
||||
# { CTRL, ALT } + u for undo
|
||||
"\eu": undo
|
||||
"\C-u": undo
|
||||
|
||||
# { up, down } for history search
|
||||
"\e[A": history-search-backward
|
||||
"\e[B": history-search-forward
|
||||
|
||||
@@ -74,4 +74,11 @@ inoremap <A-k> <Esc>:m .-2<CR>==gi
|
||||
vnoremap <A-j> :m '>+1<CR>gv=gv
|
||||
vnoremap <A-k> :m '<-2<CR>gv=gv
|
||||
|
||||
" Undo/Redo
|
||||
inoremap <C-U> <Esc>g-i
|
||||
nnoremap <C-U> g-
|
||||
inoremap <A-u> <Esc>g+a
|
||||
nnoremap <A-u> g+
|
||||
nnoremap <C-A-u> :earlier 1f<CR>
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user