geeeek
geeeek

Reputation: 415

How to disable command history (q:) in vim?

I have a habit of pressing q key when vim requires press any keys to continue.

Now, when I press : key to go command mode. Vim go command history because vim had : key in key buffer.

I want to disable q:. Is it possible to disable q:?

Upvotes: 9

Views: 2311

Answers (1)

DJMcMayhem
DJMcMayhem

Reputation: 7679

It's not possible to disable that feature, but you can disable the key bindings that trigger it. I have this in my .vimrc

nnoremap q: <nop>
nnoremap Q <nop>

and that works very well for me.

Upvotes: 16

Related Questions