It looks like you're unknowingly using
bash in its
vi has an insert mode where you can insert text (and a replace mode which is a variation on that) and a command mode where you can enter motion or action commands such as
x to delete a character,
b to move back one word, etc.
You switch from insert/replace mode to command mode with Esc, and a few commands such as
s... can make you enter insert mode from command mode.
In command mode, the
v command brings up an editor to edit the current line (the
vi editor had no command bound to
v, so ksh (on which bash is based) was free to use that for that specific task).
Here, it sounds to me that you're not expecting to be using the
vi style of key binding.
readline's default key binding is
vi, so I suspect you or your system administrator has introduced some customisation that enables the
vi mode by default.
It could be by adding a
set -o vi in
/etc/bash.bashrc wherever the system default customisation file for
bash is on your system, or
set editing-mode vi in
Or it could be that you have similar settings in your own
You'd likely want to change it back to
set -o emacs in
set editing-mode emacs in
Note that the
emacs mode has a similar function bound to Ctrl+XCtrl+E
If you're expecting to be using the
vi mode, and you don't want
v to spawn an editor, then you can assign a widget to
v other than
edit-and-execute-command such as:
bind -m vi-command '"v": abort'
Or to an empty string so it's ignored:
bind -m vi-command '"v": ""'