I am using the plugin ag.vim in Vim, and I want to do a simple re-mapping.
When I run ag with :Ag
I want remap it to :ag
so I don't have to use shift.
example: :ag string_to_find
instead of :Ag string_to_find
How can I do this?
I am using the plugin ag.vim in Vim, and I want to do a simple re-mapping.
When I run ag with :Ag
I want remap it to :ag
so I don't have to use shift.
example: :ag string_to_find
instead of :Ag string_to_find
How can I do this?
You shouldn't. Lowercase commands are reserved for built-in commands, and the norm/rules are to start custom commands with an uppercase character (just like with functions).
See Is it possible to remap an Ex command in Vim (remap :Ack to :ack)?
This isn't exactly what you asked for, but dding the following will allow you to just type 'ag' to search:
map ag :Ag
EDIT: The downvoters are right and this is a bad answer. I'll leave it here so future searchers know it's wrong.
Try:
command: Ag ag
See :help command for more.