In VIM, is there a way to bind a key to a shell command? For example when F3 is pressed git commit -a -m "test"
should be executed.
Vim – Bind a key to a bash command
vim
vim
In VIM, is there a way to bind a key to a shell command? For example when F3 is pressed git commit -a -m "test"
should be executed.
Best Answer
Try
map <F3> :!sh -xc 'git commit -a -m "test"'
.