On May 13, 4:42 pm, Gary Johnson <[email protected]> wrote: > On 2011-05-13, cyboman wrote: > > On May 13, 3:52 pm, Gary Johnson wrote: > > > On 2011-05-13, cyboman wrote: > > > > i'm trying to set a path for my gmake.exe in WinXP. unfortunately it > > > > just happens so that company i'm working for has gmake.exe on a per > > > > project basis. i.e. > > > > > C:\Documents and Settings\username\projects\projectname\trunk\tools > > > > \gmake.exe > > > > [...] > > > > > would anybody know how to make vim execute gmake.exe which is located > > > > in directories with spaces in their names (other than simply moving > > > > gmake.exe to a directory with a name without spaces in it) > > > > let &makeprg = '"C:\Documents and > > > Settings\username\projects\projectname\trunk\tools\gmake.exe"' > > > > should do it, as should > > > > set makeprg=\"C:\\Documents\ and\ > > > Settings\\username\\projects\\projectname\\trunk\\tools\\gmake.exe\" > > > > The solution is a combination of giving Windows the full path > > > enclosed in double-quotes and quoting the result properly for Vim. > > > I find it easier to first get a string to work with :let, then > > > translate the working string to one that works with :set. > > > > Regards, > > > Gary > > > thanks for the attempt to help out but unfortunately both ways didn't > > work. i'm getting the following message from vim: > > 'C:\Documents' is not recognized as internal or external command > > > how can this be fixed? > > Are you sure you included the " in your settings? The two " > characters must be passed to Windows. I tested both solutions on an > XP system and they worked fine. > > The actual settings I tried were > > let &makeprg = '"C:\Program Files\ctags58\ctags"' > set makeprg=\"C:\\Program\ Files\\ctags58\\ctags\" > > since I don't have any executables under "Documents and Settings". > The result from executing ":make" was > > :!"C:\Program Files\ctags58\ctags" > >C:DOCUME~1\username\LOCALS~1\Temp\VIe1FCF.tmp 2>&1 > [No write since last change] > shell returned 1 > (1 of 1): ctags: no files specified. Try "ctags --help". > Press ENTER or type command to continue > > Regards, > Gary
i figured what the problem was with my setup. i needed to have --win32 option there let &makeprg = '"C:\Documents and Settings\username\projects \projectname\trunk\tools\gmake.exe --win32"' set makeprg=\"C:\\Documents\ and\ Settings\\username\\projects\ \projectname\\trunk\\tools\\gmake.exe\ -win32" both of them didn't work. i needed to change it to the following let &makeprg = '"C:\Documents and Settings\username\projects \projectname\trunk\tools\gmake.exe" --win32' set makeprg=\"C:\\Documents\ and\ Settings\\username\\projects\ \projectname\\trunk\\tools\\gmake.exe\"\ --win32 once i did that it all worked. thanks for your help Gary. -- You received this message from the "vim_use" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php
