Disabling Right Click Visual Mode on VIM editor

Every once in a while software developers do dumb things. I found this to be the case with a new ‘feature’ of the VIM editor where a right click brings up the visual mode of the vim editor. I hate this. Pressing ‘v’ is easy enough for me if I need to enter visual mode. To boot, this functionality made pasting from an external source much more difficult. There are a lot of ways to disable this feature, but my preferred method is to create a line item in my users .vimrc file like this:

touch ~/.vimrc
echo "set mouse-=a" > ~/.vimrc
source ~/.vimrc

*Note that you only need to enter the first command if your user does not already have a .vimrc file.*

Leave a Reply

%d bloggers like this: