[EMAIL PROTECTED] wrote:
Hi vimmers,

I have WinXPSP2 and installed gvim 7.1, taglist plugin 4.2, cygwin with the
most up-to-date version DLL.

The issue is: run gvim from windows will fail the taglist plugin, taglist
plugin only works when I launch gvim from within cygwin bash, (Yes I am
running the windows native gvim.exe from within cygwin bash shell) it has
been a long time and I still cannot spot where the problem is.

I set 'c:\cygwin\bin\bash' as my shell, the cygwin has /bin/ctags, which is
Exuberant Ctags 5.6. Taglist plugin from within cygwin console vim works
well.

When I start gvim7 from start menu (or by any windows-way such as
right-click or launch in explorer), and launch taglist with :Tlist, error
reported such as:
Taglist: Failed to generate tags for D:/panshizhu/blabla.cpp
[EMAIL PROTECTED]@ctags: cannot sort tag file : No such file or
directory^@

where “输入文件指定了两次。” in the above message means: "The input file is
specified twice.".

I then wonder if there's any difference running from within cygwin shell
and startmenu shortcut. I found the following:

near the error line: the verbose information is:
line xx:     let cmd_output = system(ctags_cmd)
Calling shell to execute: "/usr/bin/ctags -f - --format=2 --excmd=pattern
--fields=nks --sort=yes --language-force=vim --vim-types=avf
\"D:/panshizhu/blabla.cpp\" >D:/temp/VIo74.tmp 2>&1"

The ctags_cmd proves to be the same, either run gvim from cygwin shell or
from startmenu shortcut.

Then I think the system() function taking different options,
but I checked that 'shell' 'shellcmdflag' 'shellxquote' 'shellredir' all
are the same.

At last, I think there may be multiple versions of ctags in my computer,
but that's wrong, the only ctags is in my c:/cygwin/bin/ctags, which is
equivalent to /bin/ctags inside cygwin bash shell.

Then may be the environment variable are different? check my env by :!set
inside gvim: Most things are the same except some settings in my .bashrc,
the PATH, HOME and LS_COLORS, I don't think it can cause system() report an
error.

My question is:
1. where does the error
[EMAIL PROTECTED]@ctags: cannot sort tag file : No such file or
directory^@
come from? the system() function, or the bash shell, or the ctags program?
It seems that the ctags are launched, so may be the arguments are passed
wrong? or I may have missed something?

2. if the problem cannot be identified, anybody has a solution to keep
using cygwin bash as gvim shell and use cygwin ctags inside taglist for
windows gvim? —— I did make them work the last year, but when I reinstalled
my WindowsXP I cannot remember how to get them work that way.

--
Sincerely, Pan, Shi Zhu. ext: 2606



If your shell is cmd.exe, "/usr/bin/ctags" will give "Unknown command or file name". If you want to mix Dos shells and cygwin utilities, you will have to juggle with the path formats: see "man cygpath" from within cygwin.


Best regards,
Tony.
--
"Not only is God dead, but just try to find a plumber on weekends."
                -- Woody Allen

Reply via email to