|
:grep always terminates with E40 "Can't open errorfile", whereas !!ls works set shell=bash set shellcmdflag=--norc\ -c set shellquote= set shellxquote=\" set shellslash set grepformat=%*[^\w]\ %l\ %f\ %m,%f:%l:%m,%f:%l%m,path\ %l\ %f\ ,%f\ %l%m set grepprg=/usr/bin/find\ .\ -name\ '*.cpp'\ -or\ -name\ '*.cs'\ -or\ -name\ '*.c'\ -or\ -name\ '*.asm'\ -or\ -name\ '*.h'\ -or\ -name\ '*.ini'\ -or\ -name\ '*.reg'\ \\\\|\ xargs\ grep\ -nH\ $* The command works when executed from the terminal. Do you have any hints? Boris --~--~---------~--~----~------------~-------~--~----~ You received this message from the "vim_mac" maillist. For more information, visit http://www.vim.org/maillist.php -~----------~----~----~----~------~----~------~--~--- |
|
Boris wrote: > :grep always terminates with E40 "Can't open errorfile", whereas !!ls > works > > set shell=bash > set shellcmdflag=--norc\ -c > set shellquote= > set shellxquote=\" > set shellslash > set grepformat=%*[^\w]\ %l\ %f\ %m,%f:%l:%m,%f:%l%m,path\ %l\ %f\ ,%f\ > %l%m > set grepprg=/usr/bin/find\ .\ -name\ '*.cpp'\ -or\ -name\ '*.cs'\ -or\ > -name\ '*.c'\ -or\ -name\ '*.asm'\ -or\ -name\ '*.h'\ -or\ -name\ > '*.ini'\ -or\ -name\ '*.reg'\ \\\\|\ xargs\ grep\ -nH\ $* > > The command works when executed from the terminal. Do you have any > hints? > Boris Looks to me like the shellcmdflag is the culprit. My bash grumps "--norc -c: invalid option" which suggests what you intended to be two options is being passed as one. If that's not it, I'd look to shellslash which may be changing that backslash before your pipe into a forward slash and screwing things up (though if you're on the Mac I don't see why that option would be available/useful anyway). And if not that, I'd try doing :set verbose=5 or some number in that vicinity and looking at what Vim outputs. Ben. --~--~---------~--~----~------------~-------~--~----~ You received this message from the "vim_mac" maillist. For more information, visit http://www.vim.org/maillist.php -~----------~----~----~----~------~----~------~--~--- |
|
Sorry Ben, I'd mixed up the settings with the one of my Windows installation (where it works). My settings on MacVim are actually set shell=bash set shellcmdflag=-c set shellquote= set shellxquote=\" set noshelltemp Here is what macvim says with verbose=5 bash: /usr/bin/find . -name '*.cpp' -or -name '*.cs' -or -name '*.c' - or -name '*.asm' -or -name '*.h' -or -name '*.ini' -or -name '*.reg' | xargs grep -nH renewcommand 2>&1| tee /var/folders/RY/ RYGxulQVHJO96WoXLe3tp++++TI/-Tmp-/v528793/2: No such file or directory Any idea? --~--~---------~--~----~------------~-------~--~----~ You received this message from the "vim_mac" maillist. For more information, visit http://www.vim.org/maillist.php -~----------~----~----~----~------~----~------~--~--- |
|
Boris wrote: > Sorry Ben, I'd mixed up the settings with the one of my Windows > installation (where it works). My settings on MacVim are actually > > set shell=bash > set shellcmdflag=-c > set shellquote= > set shellxquote=\" > set noshelltemp > > Here is what macvim says with verbose=5 > > bash: /usr/bin/find . -name '*.cpp' -or -name '*.cs' -or -name '*.c' - > or -name '*.asm' -or -name '*.h' -or -name '*.ini' -or -name '*.reg' | > xargs grep -nH renewcommand 2>&1| tee /var/folders/RY/ > RYGxulQVHJO96WoXLe3tp++++TI/-Tmp-/v528793/2: No such file or directory > > Any idea? I think you want shellxquote set to blank. It looks like bash is interpreting the entire commandline as a single quoted string and trying to find an executable with that name. Ben. --~--~---------~--~----~------------~-------~--~----~ You received this message from the "vim_mac" maillist. For more information, visit http://www.vim.org/maillist.php -~----------~----~----~----~------~----~------~--~--- |
|
Thanks! That's it On Aug 1, 1:54 am, Ben Schmidt <[hidden email]> wrote: > Boris wrote: > > Sorry Ben, I'd mixed up the settings with the one of my Windows > > installation (where it works). My settings on MacVim are actually > > > set shell=bash > > set shellcmdflag=-c > > set shellquote= > > set shellxquote=\" > > set noshelltemp > > > Here is what macvim says with verbose=5 > > > bash: /usr/bin/find . -name '*.cpp' -or -name '*.cs' -or -name '*.c' - > > or -name '*.asm' -or -name '*.h' -or -name '*.ini' -or -name '*.reg' | > > xargs grep -nH renewcommand 2>&1| tee /var/folders/RY/ > > RYGxulQVHJO96WoXLe3tp++++TI/-Tmp-/v528793/2: No such file or directory > > > Any idea? > > I think you want shellxquote set to blank. It looks like bash is > interpreting the entire commandline as a single quoted string and trying > to find an executable with that name. > > Ben. You received this message from the "vim_mac" maillist. For more information, visit http://www.vim.org/maillist.php -~----------~----~----~----~------~----~------~--~--- |
| Powered by Nabble | See how NAML generates this page |
