Check for full match of command name

This commit is contained in:
Jacob Niehus 2014-12-07 13:19:09 -07:00
parent 2ee153d610
commit 53cc8a53d9

View file

@ -171,7 +171,7 @@ function! plug#end()
endif endif
call add(s:triggers[name].map, cmd) call add(s:triggers[name].map, cmd)
elseif cmd =~ '^[A-Z]' elseif cmd =~ '^[A-Z]'
if !exists(':'.cmd) if exists(':'.cmd) != 2
execute printf( execute printf(
\ 'command! -nargs=* -range -bang %s call s:lod_cmd(%s, "<bang>", <line1>, <line2>, <q-args>, %s)', \ 'command! -nargs=* -range -bang %s call s:lod_cmd(%s, "<bang>", <line1>, <line2>, <q-args>, %s)',
\ cmd, string(cmd), string(name)) \ cmd, string(cmd), string(name))