please see my inputs inline.
----- Original Message ----
From: Shigio YAMAGUCHI <address@hidden>
To: Ritesh Banerjee <address@hidden>
Sent: Tuesday, April 8, 2008 4:38:55 AM
Subject: Re: Regarding gtags.vim improvements
On Mon, 7 Apr 2008 01:52:47 -0700 (PDT)
Ritesh Banerjee <address@hidden
> [Ritesh] Thanks, I tried this to do this. It gives the same error.
> However, on double checking, global-0.7 tar only contains version 0.2 (so no surprise).
> Could you send the gtags.vim you mention ? As I explained its to do with the system() with '>'
> on Windows (as far as I could get it).
Sorry but I don't know global-0.7.
Version 0.3 of gtags.vim is included in GLOBAL-5.7, and it works only with GLOBAL-5.7.
You can download it from here:http://www.gnu.org/software/global/download.html
[Ritesh] Oops, I meant global-5.7. But re-checking, it seems I copied the gtags.vim locally on my disk over from the older global-4.x version I had. I tested with
version 0.3 - it works on Windows :-) The only drawback is that it opens a window running the '!' command till the command is executing. So, I'll prefer some alternate way - i'll move the changes to gtags.vim 0.3 script ...
By the way, GLOBAL doesn't support Windows environments. Please see README, INSTALL or FAQ.
[Ritesh] I couldn't use global for long due to this restriction. However, since ports are available and downloadable from global website, I thought you are in favour of global running on more platforms :-)
And with gtags.vim v0.3, it does...
> [Ritesh] Here is the output using -t, -x, and --result grep. For me personally,
> grep mode works best
> -----> Using '-x' -------------->
> || saveenv_copy 329 u-boot/common/upgrade.c saveenv_copy();
> || saveenv_copy 164 users/ifx/utilities/command.c int
> -----> Using '-t' -------------->
> || saveenv_copy u-boot/common/upgrade.c 329
> || saveenv_copy users/ifx/utilities/command.c 164
> -----> Using '--result grep' -------------->
> || Global:Searching [-g] for [saveenv_copy]
> u-boot\common\upgrade.c|329| saveenv_copy();
> users\ifx\utilities\command.c|164| int saveenv_copy()
> As you can see, the '--result grep' has less duplication and looks cleaner.
It seems that the above vim scripts using '-x' and '-t' don't work correctly.
Perhaps, variable '&efm' is not correctly set.
[Ritesh] The new script shows results which are like the '-grep' option I tried out ..
> [Ritesh] I didn't get this, I am afraid ? I don't need to count any lines.
> vim quickfix takes care of
everything, its OS independent,
> and its faster than the other method... In case of no match, we onlu get the print like
> "Global:Searching [-r] for [saveenv_copy]" makes it reasonably obvious if there is no match...
In case of no match, vim should print an obvious error message like "Pattern 'XXX' not found."
in a suitable place for the error message. I think quickfix window is not the place.
[Ritesh] I see what you mean, but as a regular vim user, I don't expect any special error message in quickfix list, so for me that's usual behavior. I realize, others may expect differently.
You can get an error message ("No more items"), by some mechanism :-) Please see attached gtags.vim v0.3 with my changes (if this helps x-reference the discussion). It manages to print a message if no matches are found...
Because gtags.vim version 0.3 requires GLOBAL-5.7, I hesitate to update just the gtags.vim.
For the time
being, I would like to distribute gtags.vim 0.3 as part of GLOBAL-5.7.
[Ritesh] I understand. However, many people download plugins of vim plugin site. So, you could upload gtags.vim v0.3 clearly noting that global-5.7 needs to be used. You can also edit the intro text. Just some thoughts from an end-user.
Shigio YAMAGUCHI <address@hidden
> - GNU Project
PGP fingerprint: D1CB 0B89 B346 4AB6 5663 C4B6 3CA5 BBB3 57BE DDA3