On Fri, 2006-06-23 at 00:03 +0200, A.J.Mechelynck wrote: > Hm. With which pattern are you invoking this command? And what is the > current directory? (use the ":pwd" command if you arren't sure.)
I'm on /home/dpm/project/src, editing myfile.c. I don't know whether this is relevant, but I usually start editing files with gvim by right-clicking on them on the file manager and choosing "Edit with GVim" (I'm using Nautilus on GNOME). The only side-effect of this, is that the pwd is always set to /home/dpm, so I usually have to do an :lcd %:h if I need to do any file-related stuff. So, to recap: * My .vimrc contains this: command! VimGrep -nargs=1 -bar -bang \ vimgrep<bang> <args> ../inc/*.h ../src/*.c (I guess that ../src/*.c should simply be *.c, but changing that does not solve the issue) * pwd returns /home/dpm/project/src * It doesn't matter which pattern I use, I always get the "E488: Trailing characters" whenever I execute: :VimGrep pattern as an example, the last pattern I used was: :VimGrep static Thanks for your help (and your patience).