Re: gundo not working

2016-09-18 Thread Steve

Le 18-09-2016, à 12:36:24 -0700, Ben Fritz a écrit :



By default Vim does NOT load plugins from the ~/.vim/bundle directory.
Do you have a plugin such as Pathogen installed and configured to do
that for you?


No.


If you're using a recent version of vim (8.0 or one of the earlier
patches leading up to it) you can move it to


Currently using vim 8.0, patch 1-3


~/.vim/pack/whatever-name-you-want/start/gundo instead of
~/.vim/bundle/gundo, and it should "just work". In earlier Vims you
need a plugin to enable this sort of plugin loading.


I did:

mv ~/.vim/bundle/gundo ~/.vim/pack/plugins/start/gundo

then reloaded vim and when tried to execute ',u' (which is u), I get

E492: Commande inconnue: gUndoToggle

though this command exist in the gundo package:

grep -irn  gundotoggle *
autoload/gundo.py:522:  vim.command('GundoToggle')
autoload/gundo.vim:18:  command! -nargs=0 GundoToggle call 
s:GundoDidNotLoad()
autoload/gundo.vim:70:  command! -nargs=0 GundoToggle call 
s:GundoDidNotLoad()
autoload/gundo.vim:297:  command! -nargs=0 GundoToggle call s:GundoDidNotLoad()
autoload/gundo.vim:320:function! s:GundoToggle()"{{{
autoload/gundo.vim:453:function! gundo#GundoToggle()"{{{
autoload/gundo.vim:454:call s:GundoToggle()
doc/gundo.txt:56:nnoremap  :GundoToggle
doc/gundo.txt:290:* Make GundoToggle close the Gundo windows if they're 
visible but not the
plugin/gundo.vim:20:command! -nargs=0 GundoToggle call gundo#GundoToggle()
site/index.html:133:nnoremap F5 
:GundoToggleCR
site/index.html:145:nnoremap F5 
:GundoToggleCR
site/index.html:510:Make 
GundoToggle close the Gundo windows if they're


what did I miss?


Thanks for your answer.
Steve

PS: no need to Cc me, I'm subscribed to the list.



(Post writing: I noticed the command in the nnoremap was not written the same
as in the error, so I adjusted that. After that, the error was not the same,
but was:

Gundo requires Vim to be compiled with Python 2.4+

I'll try that tomorrow)

--
--
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

--- 
You received this message because you are subscribed to the Google Groups "vim_use" group.

To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_use+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: turn all highlighting off at startup

2016-09-18 Thread jleiss


Syntax off did it, Ben.  Thanks!

-- 
-- 
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

--- 
You received this message because you are subscribed to the Google Groups 
"vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_use+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: turn all highlighting off at startup

2016-09-18 Thread Ben Fritz
On Sunday, September 18, 2016 at 2:34:28 PM UTC-5, jle...@nc.rr.com wrote:
> What am I doing wrong?  I thought I knew how to do this.  When it didn't 
> work, I studied the help manual, but I guess I'm still doing something wrong. 
>  I'm using Vim 8.0.2.  I put set syntax=off in the _vimrc file, and it didn't 
> work.  Nothing else I tried worked.  I want to turn all highlighting off for 
> all files.  I am using Windows 10 64-bit on a Dell laptop.  Any suggestion?  
> Thanks, Jack Leiss jle...@nc.rr.com .

Have you tried "syntax off" instead of "set syntax=off"?

I think that will do it, but you may also need to put "filetype off" in your 
vimrc as well, unless you need filetype detection but not syntax highlighting 
for some reason.

-- 
-- 
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

--- 
You received this message because you are subscribed to the Google Groups 
"vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_use+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: using cscope with tabs

2016-09-18 Thread Ben Fritz
On Sunday, September 18, 2016 at 2:39:33 AM UTC-5, roy rosen wrote:
> Hi all,
> 
> I am using cscope with vim and have the following mapping in my .vimrc:
> 
> nmap s :tab cs find s =expand("")
> 
> this works fine except for the fact that it is opening a new tab every
> time I use it.
> I want to open a new tab only if the file does not exist in one of the
> already opened tabs.
> If it already exist, use this tab.
> This is the normal behavior of most other IDEs.
> 
> Can someone tell me how to change the mapping?
> 
> Thanks, Roy.

Not sure if it will work, but have you tried adding "usetab" to your 
'switchbuf' setting value? :help 'switchbuf'

-- 
-- 
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

--- 
You received this message because you are subscribed to the Google Groups 
"vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_use+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: gundo not working

2016-09-18 Thread Ben Fritz
On Sunday, September 18, 2016 at 6:42:55 AM UTC-5, Steve wrote:
> Hi there !
> 
> I installed gundo with:
> 
> git clone http://github.com/sjl/gundo.vim.git ~/.vim/bundle/gundo
> 
> Then insereted
> 
> nnoremap u :gUndoToggle
> 
> saved, closed the file and edited a new one. After a while, I tried to
> use gundo by issuing ,u, but nothing happened.
> 
> I'm working on a Debian Jessie box but with a self-compiled vim 8.
> 
> How can I debug this?
> 

By default Vim does NOT load plugins from the ~/.vim/bundle directory. Do you 
have a plugin such as Pathogen installed and configured to do that for you?

If you're using a recent version of vim (8.0 or one of the earlier patches 
leading up to it) you can move it to 
~/.vim/pack/whatever-name-you-want/start/gundo instead of ~/.vim/bundle/gundo, 
and it should "just work". In earlier Vims you need a plugin to enable this 
sort of plugin loading.

-- 
-- 
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

--- 
You received this message because you are subscribed to the Google Groups 
"vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_use+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


turn all highlighting off at startup

2016-09-18 Thread jleiss
What am I doing wrong?  I thought I knew how to do this.  When it didn't work, 
I studied the help manual, but I guess I'm still doing something wrong.  I'm 
using Vim 8.0.2.  I put set syntax=off in the _vimrc file, and it didn't work.  
Nothing else I tried worked.  I want to turn all highlighting off for all 
files.  I am using Windows 10 64-bit on a Dell laptop.  Any suggestion?  
Thanks, Jack Leiss jle...@nc.rr.com .

-- 
-- 
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

--- 
You received this message because you are subscribed to the Google Groups 
"vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_use+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


syntax match bug: 'keepend' not officially supported, but required in some cases

2016-09-18 Thread Brett Stahlman
The syntax documentation suggests that the 'keepend' argument applies
only to syntax regions, not syntax matches. But if I highlight a
buffer containing only the following line...

ABCDE

...with the following syntax definitions...

syn match A /A/
syn match Inside /[A-Z]\+/ transparent contained containedin=A
hi A guifg=blue

...the match group "A" extends (apparently incorrectly) from A through
E, though its pattern matches only the "A". Stranger still, one
additional nested "Inside" group is recognized in each successive
letter. I.e., "Inside" is contained within "Inside", in spite of the
`containedin=A'. Thus, running synstack on successive characters, I
see...

-- cursor on A --
A
Inside
-- cursor on B --
A
Inside
Inside
-- cursor on C --
A
Inside
Inside
Inside


I can fix the problem by adding the 'keepend' argument to the
definition for match group "A", but the "keepend" is highlighted as an
error by the vim syntax, and the help on :syn-match gives me no reason
to believe the argument should be supported.

Here are the results of synstack() with the following, "fixed" definition for A:
syn match A /A/ keepend

-- cursor on A --
A
Inside
-- cursor on B --
-- cursor on C --

Is 'keepend' meant to be supported for syn-match? The purpose of
'keepend' is to prevent a nested group from obscuring a match with a
containing group's "end pattern". Although a match group has no
explicit end pattern, the principle of checking for the end of the
match pattern certainly still applies, so I suppose it makes sense
that 'keepend' would be accepted for both syn-match and syn-region. If
that is the intent, then the documentation needs fixing.

As for the infinitely nested "Inside" groups, I can't account for
that, and suspect it's a bug, but perhaps I'm misunderstanding
something about contained and containedin?

Thanks,
Brett Stahlman

-- 
-- 
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

--- 
You received this message because you are subscribed to the Google Groups 
"vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_use+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: norm 1G does not work on vim8.0.4

2016-09-18 Thread Ni Va
On Sunday, September 18, 2016 at 1:21:53 PM UTC+2, Tim Chase wrote:
> On 2016-09-18 02:55, Ni Va wrote:
> > > And stepping back, if you're writing *either* "norm 1G" or "norm!
> > > 1G" just write
> > > 
> > >   1
> > > 
> > > or whichever line-number you want to go to.  Likewise, just use
> > > "$" rather than "norm G" or "norm! g"
> > > 
> > >   :help range
> > > 
> > > -tim  
> > 
> > Thank you men for advices, it is located in a buffer opened by the
> > plugin Vimfiler that aims to review natural original vim mapping.
> > 
> > I was'not writing but just readgin and wanted to see the first line
> > of buffer so when I'm in normal mode I don't want to switch to
> > command mode with :[range]move {address}
> 
> I'm not suggesting using ":[range]move {address}" but rather just the
> number.  So instead of your script looking something like
> 
>   function! Test(...)
> call do_something(args)
> norm! 1G
> call do_something_else(args)
>   endfunction
> 
> it would instead just read
> 
>   function! Test(...)
> call do_something(args)
> 1
> call do_something_else(args)
>   endfunction
> 
> -tim

Oh ok Tim. Thanks a lot.

-- 
-- 
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

--- 
You received this message because you are subscribed to the Google Groups 
"vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_use+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


gundo not working

2016-09-18 Thread Steve

Hi there !

I installed gundo with:

git clone http://github.com/sjl/gundo.vim.git ~/.vim/bundle/gundo

Then insereted

nnoremap u :gUndoToggle

saved, closed the file and edited a new one. After a while, I tried to
use gundo by issuing ,u, but nothing happened.

I'm working on a Debian Jessie box but with a self-compiled vim 8.

How can I debug this?

Thanks,
Steve

--
--
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

--- 
You received this message because you are subscribed to the Google Groups "vim_use" group.

To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_use+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: norm 1G does not work on vim8.0.4

2016-09-18 Thread Tim Chase
On 2016-09-18 02:55, Ni Va wrote:
> > And stepping back, if you're writing *either* "norm 1G" or "norm!
> > 1G" just write
> > 
> >   1
> > 
> > or whichever line-number you want to go to.  Likewise, just use
> > "$" rather than "norm G" or "norm! g"
> > 
> >   :help range
> > 
> > -tim  
> 
> Thank you men for advices, it is located in a buffer opened by the
> plugin Vimfiler that aims to review natural original vim mapping.
> 
> I was'not writing but just readgin and wanted to see the first line
> of buffer so when I'm in normal mode I don't want to switch to
> command mode with :[range]move {address}

I'm not suggesting using ":[range]move {address}" but rather just the
number.  So instead of your script looking something like

  function! Test(...)
call do_something(args)
norm! 1G
call do_something_else(args)
  endfunction

it would instead just read

  function! Test(...)
call do_something(args)
1
call do_something_else(args)
  endfunction

-tim



-- 
-- 
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

--- 
You received this message because you are subscribed to the Google Groups 
"vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_use+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: norm 1G does not work on vim8.0.4

2016-09-18 Thread Ni Va
On Sunday, September 18, 2016 at 3:54:10 AM UTC+2, Tim Chase wrote:
> On 2016-09-18 03:57, Nikolay Aleksandrovich Pavlov wrote:
> > And if you are writing `norm 1G` somewhere (e.g. in a plugin), then
> > just write it as `normal! 1G` (with bang).
> 
> And stepping back, if you're writing *either* "norm 1G" or "norm! 1G"
> just write
> 
>   1
> 
> or whichever line-number you want to go to.  Likewise, just use "$"
> rather than "norm G" or "norm! g"
> 
>   :help range
> 
> -tim

Thank you men for advices, it is located in a buffer opened by the plugin 
Vimfiler
that aims to review natural original vim mapping.

I was'not writing but just readgin and wanted to see the first line of buffer
so when I'm in normal mode I don't want to switch to command mode with
:[range]move {address}

-- 
-- 
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

--- 
You received this message because you are subscribed to the Google Groups 
"vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_use+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


using cscope with tabs

2016-09-18 Thread roy rosen
Hi all,

I am using cscope with vim and have the following mapping in my .vimrc:

nmap s :tab cs find s =expand("")

this works fine except for the fact that it is opening a new tab every
time I use it.
I want to open a new tab only if the file does not exist in one of the
already opened tabs.
If it already exist, use this tab.
This is the normal behavior of most other IDEs.

Can someone tell me how to change the mapping?

Thanks, Roy.

-- 
-- 
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

--- 
You received this message because you are subscribed to the Google Groups 
"vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_use+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.