Friday, July 31, 2015
Re: dbext.vim bug: jumplist pollution caused by BufRead handler
<dfishburn.vim@gmail.com> wrote:
>
>
> On Sun, Apr 12, 2015 at 4:43 PM, Justin M. Keyes <justinkz@gmail.com> wrote:
>>
>> dbext's BufRead handler (and maybe others) adds a spurious mark at
>> line 1 of each buffer. This is very annoying. Steps to reproduce:
>>
>> :h h
>> :h a
>> <c-o>
>>
>> The <c-o> step will go to the top of the file instead of the previous
>> ":h h" location. Another <c-o> will then go to the ":h h" location.
>>
>
> This has been fixed in the soon to be released dbext 22.0
>
> Thanks for the report Justin.
Thanks David!
Justin M. Keyes
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Is there a repository of spell files for different languages?
> Is there a repository of spell files for different languages?
>
> Googling i found a link to
> <ftp://ftp.vim.org/pub/vim/runtime/spell/> but it seems to be dead.
It's not dead, it's just that nobody sends spell file updates.
> Even though it turned out to be a piece of cake to build .spl
> files once you have gotten hold of an appropriate
> OpenOffice/LibreOffice 'dictionary' file maybe it would be a good
> idea to create a public repository somewhere. I'm thinking GitHub
> because then people can contribute files they created themselves
> by doing a pull request. I'd be willing to build .spl files from
> existing OO/LO 'dictionaries' and maintain the repository if the
> OO/LO licenses permit it and there is an interest.
If you can just run the scripts to update the spell files, and adjust
the scripts where needed, that would be good. The resulting spell files
do need to go on the ftp site, that's where Vim gets them from.
--
DINGO: Wicked wicked Zoot ... she is a bad person and she must pay the
penalty. And here in Castle Anthrax, we have but one punishment
... you must tie her down on a bed ... and spank her. Come!
GIRLS: A spanking! A spanking!
"Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD
/// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Persistent undo and force quit
> On Jul 28, 2015 18:31, "David Besen" <[hidden email]> wrote:
> >
> > Second draft, seems to work a little better:
> >
> > "save undo if we qa!
> > function! MyWundoQuit()
> > let undoseq = undotree().seq_cur
> > earlier 1f
> > let undof = escape(undofile(expand('%')),'% ')
> > exec "wundo " . undof
> > silent! exec "u " . undoseq
> > endfunction
> >
> > autocmd BufWinLeave * call MyWundoQuit()
> Why does the second draft still have "earlier 1f" ? Why can't you just write the undo file?
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Python load error
:)
On Friday, July 31, 2015 at 12:59:27 PM UTC-4, Lorenzo Fontana wrote:
> Can you try to remove the old copy. I think it should be brew remove vim
>
> On Jul 31, 2015 6:54 PM, "Ratan" <ratan...@gmail.com> wrote:
> On Friday, July 31, 2015 at 12:35:27 PM UTC-4, Lorenzo Fontana wrote:
>
> > On Friday, July 31, 2015 at 6:25:02 PM UTC+2, Ratan wrote:
>
> > > On Friday, July 31, 2015 at 12:19:06 PM UTC-4, Lorenzo Fontana wrote:
>
> > > > On Friday, July 31, 2015 at 6:18:27 PM UTC+2, Lorenzo Fontana wrote:
>
> > > > > On Friday, July 31, 2015 at 6:10:37 PM UTC+2, Ratan wrote:
>
> > > > > > On Friday, July 31, 2015 at 11:58:48 AM UTC-4, Lorenzo Fontana wrote:
>
> > > > > > > What's the output of vim --version | grep python ?
>
> > > > > > Some info:
>
> > > > > > python version: 2.7.10
>
> > > > > > vim version: 7.4.712
>
> > > > > > os x yosemite
>
> > > > > >
>
> > > > > > Full output of command:
>
> > > > > > +cryptv +linebreak +python +viminfo
>
> > > > > > +cscope +lispindent -python3 +vreplace
>
> > > > > > Linking: /usr/bin/clang -L. -L/usr/local/lib -L/usr/local/lib -F/usr/local/Frameworks -Wl,-headerpad_max_install_names -o vim -lm -lncurses -liconv -framework Cocoa -fstack-protector -L/System/Library/Perl/5.18/darwin-thread-multi-2level/CORE -lperl -F/usr/local/Cellar/python/2.7.10/Frameworks -framework Python -lruby.2.0.0 -lobjc
>
> > > > >
>
> > > > >
>
> > > > > The error you do something like this, the error appears?
>
> > > > >
>
> > > > > :python print 'Hi!'
>
> > > >
>
> > > >
>
> > > > Sorry,
>
> > > > If you do something like this, the error appears?
>
> > > >
>
> > > > :python print 'Hi!'
>
> > >
>
> > > Same error as above.
>
> >
>
> > So python support is present but broken.
>
> > Since you are on osx I suppose you installed vim with homebrew.
>
> >
>
> > Can you run a:
>
> > brew install --with-python
>
>
>
> brew install vim --with-python
>
> Warning: vim-7.4.712_1 already installed
Removed and uninstalled and now it works...
I really should have tried that on my own. Thank you so much!
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Python load error
> Can you try to remove the old copy. I think it should be brew remove vim
>
> On Jul 31, 2015 6:54 PM, "Ratan" <ratan...@gmail.com> wrote:
> On Friday, July 31, 2015 at 12:35:27 PM UTC-4, Lorenzo Fontana wrote:
>
> > On Friday, July 31, 2015 at 6:25:02 PM UTC+2, Ratan wrote:
>
> > > On Friday, July 31, 2015 at 12:19:06 PM UTC-4, Lorenzo Fontana wrote:
>
> > > > On Friday, July 31, 2015 at 6:18:27 PM UTC+2, Lorenzo Fontana wrote:
>
> > > > > On Friday, July 31, 2015 at 6:10:37 PM UTC+2, Ratan wrote:
>
> > > > > > On Friday, July 31, 2015 at 11:58:48 AM UTC-4, Lorenzo Fontana wrote:
>
> > > > > > > What's the output of vim --version | grep python ?
>
> > > > > > Some info:
>
> > > > > > python version: 2.7.10
>
> > > > > > vim version: 7.4.712
>
> > > > > > os x yosemite
>
> > > > > >
>
> > > > > > Full output of command:
>
> > > > > > +cryptv +linebreak +python +viminfo
>
> > > > > > +cscope +lispindent -python3 +vreplace
>
> > > > > > Linking: /usr/bin/clang -L. -L/usr/local/lib -L/usr/local/lib -F/usr/local/Frameworks -Wl,-headerpad_max_install_names -o vim -lm -lncurses -liconv -framework Cocoa -fstack-protector -L/System/Library/Perl/5.18/darwin-thread-multi-2level/CORE -lperl -F/usr/local/Cellar/python/2.7.10/Frameworks -framework Python -lruby.2.0.0 -lobjc
>
> > > > >
>
> > > > >
>
> > > > > The error you do something like this, the error appears?
>
> > > > >
>
> > > > > :python print 'Hi!'
>
> > > >
>
> > > >
>
> > > > Sorry,
>
> > > > If you do something like this, the error appears?
>
> > > >
>
> > > > :python print 'Hi!'
>
> > >
>
> > > Same error as above.
>
> >
>
> > So python support is present but broken.
>
> > Since you are on osx I suppose you installed vim with homebrew.
>
> >
>
> > Can you run a:
>
> > brew install --with-python
>
>
>
> brew install vim --with-python
>
> Warning: vim-7.4.712_1 already installed
Removed and uninstalled and now it works...
I really should have tried that on my own. Thank you so much!
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Python load error
Can you try to remove the old copy. I think it should be brew remove vim
On Friday, July 31, 2015 at 12:35:27 PM UTC-4, Lorenzo Fontana wrote:
> On Friday, July 31, 2015 at 6:25:02 PM UTC+2, Ratan wrote:
> > On Friday, July 31, 2015 at 12:19:06 PM UTC-4, Lorenzo Fontana wrote:
> > > On Friday, July 31, 2015 at 6:18:27 PM UTC+2, Lorenzo Fontana wrote:
> > > > On Friday, July 31, 2015 at 6:10:37 PM UTC+2, Ratan wrote:
> > > > > On Friday, July 31, 2015 at 11:58:48 AM UTC-4, Lorenzo Fontana wrote:
> > > > > > What's the output of vim --version | grep python ?
> > > > > Some info:
> > > > > python version: 2.7.10
> > > > > vim version: 7.4.712
> > > > > os x yosemite
> > > > >
> > > > > Full output of command:
> > > > > +cryptv +linebreak +python +viminfo
> > > > > +cscope +lispindent -python3 +vreplace
> > > > > Linking: /usr/bin/clang -L. -L/usr/local/lib -L/usr/local/lib -F/usr/local/Frameworks -Wl,-headerpad_max_install_names -o vim -lm -lncurses -liconv -framework Cocoa -fstack-protector -L/System/Library/Perl/5.18/darwin-thread-multi-2level/CORE -lperl -F/usr/local/Cellar/python/2.7.10/Frameworks -framework Python -lruby.2.0.0 -lobjc
> > > >
> > > >
> > > > The error you do something like this, the error appears?
> > > >
> > > > :python print 'Hi!'
> > >
> > >
> > > Sorry,
> > > If you do something like this, the error appears?
> > >
> > > :python print 'Hi!'
> >
> > Same error as above.
>
> So python support is present but broken.
> Since you are on osx I suppose you installed vim with homebrew.
>
> Can you run a:
> brew install --with-python
brew install vim --with-python
Warning: vim-7.4.712_1 already installed
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Python load error
> On Friday, July 31, 2015 at 6:25:02 PM UTC+2, Ratan wrote:
> > On Friday, July 31, 2015 at 12:19:06 PM UTC-4, Lorenzo Fontana wrote:
> > > On Friday, July 31, 2015 at 6:18:27 PM UTC+2, Lorenzo Fontana wrote:
> > > > On Friday, July 31, 2015 at 6:10:37 PM UTC+2, Ratan wrote:
> > > > > On Friday, July 31, 2015 at 11:58:48 AM UTC-4, Lorenzo Fontana wrote:
> > > > > > What's the output of vim --version | grep python ?
> > > > > Some info:
> > > > > python version: 2.7.10
> > > > > vim version: 7.4.712
> > > > > os x yosemite
> > > > >
> > > > > Full output of command:
> > > > > +cryptv +linebreak +python +viminfo
> > > > > +cscope +lispindent -python3 +vreplace
> > > > > Linking: /usr/bin/clang -L. -L/usr/local/lib -L/usr/local/lib -F/usr/local/Frameworks -Wl,-headerpad_max_install_names -o vim -lm -lncurses -liconv -framework Cocoa -fstack-protector -L/System/Library/Perl/5.18/darwin-thread-multi-2level/CORE -lperl -F/usr/local/Cellar/python/2.7.10/Frameworks -framework Python -lruby.2.0.0 -lobjc
> > > >
> > > >
> > > > The error you do something like this, the error appears?
> > > >
> > > > :python print 'Hi!'
> > >
> > >
> > > Sorry,
> > > If you do something like this, the error appears?
> > >
> > > :python print 'Hi!'
> >
> > Same error as above.
>
> So python support is present but broken.
> Since you are on osx I suppose you installed vim with homebrew.
>
> Can you run a:
> brew install --with-python
brew install vim --with-python
Warning: vim-7.4.712_1 already installed
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Python load error
> On Friday, July 31, 2015 at 12:19:06 PM UTC-4, Lorenzo Fontana wrote:
> > On Friday, July 31, 2015 at 6:18:27 PM UTC+2, Lorenzo Fontana wrote:
> > > On Friday, July 31, 2015 at 6:10:37 PM UTC+2, Ratan wrote:
> > > > On Friday, July 31, 2015 at 11:58:48 AM UTC-4, Lorenzo Fontana wrote:
> > > > > What's the output of vim --version | grep python ?
> > > > Some info:
> > > > python version: 2.7.10
> > > > vim version: 7.4.712
> > > > os x yosemite
> > > >
> > > > Full output of command:
> > > > +cryptv +linebreak +python +viminfo
> > > > +cscope +lispindent -python3 +vreplace
> > > > Linking: /usr/bin/clang -L. -L/usr/local/lib -L/usr/local/lib -F/usr/local/Frameworks -Wl,-headerpad_max_install_names -o vim -lm -lncurses -liconv -framework Cocoa -fstack-protector -L/System/Library/Perl/5.18/darwin-thread-multi-2level/CORE -lperl -F/usr/local/Cellar/python/2.7.10/Frameworks -framework Python -lruby.2.0.0 -lobjc
> > >
> > >
> > > The error you do something like this, the error appears?
> > >
> > > :python print 'Hi!'
> >
> >
> > Sorry,
> > If you do something like this, the error appears?
> >
> > :python print 'Hi!'
>
> Same error as above.
So python support is present but broken.
Since you are on osx I suppose you installed vim with homebrew.
Can you run a:
brew install --with-python
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Python load error
> On Friday, July 31, 2015 at 6:18:27 PM UTC+2, Lorenzo Fontana wrote:
> > On Friday, July 31, 2015 at 6:10:37 PM UTC+2, Ratan wrote:
> > > On Friday, July 31, 2015 at 11:58:48 AM UTC-4, Lorenzo Fontana wrote:
> > > > What's the output of vim --version | grep python ?
> > > Some info:
> > > python version: 2.7.10
> > > vim version: 7.4.712
> > > os x yosemite
> > >
> > > Full output of command:
> > > +cryptv +linebreak +python +viminfo
> > > +cscope +lispindent -python3 +vreplace
> > > Linking: /usr/bin/clang -L. -L/usr/local/lib -L/usr/local/lib -F/usr/local/Frameworks -Wl,-headerpad_max_install_names -o vim -lm -lncurses -liconv -framework Cocoa -fstack-protector -L/System/Library/Perl/5.18/darwin-thread-multi-2level/CORE -lperl -F/usr/local/Cellar/python/2.7.10/Frameworks -framework Python -lruby.2.0.0 -lobjc
> >
> >
> > The error you do something like this, the error appears?
> >
> > :python print 'Hi!'
>
>
> Sorry,
> If you do something like this, the error appears?
>
> :python print 'Hi!'
Same error as above.
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Python load error
> On Friday, July 31, 2015 at 6:10:37 PM UTC+2, Ratan wrote:
> > On Friday, July 31, 2015 at 11:58:48 AM UTC-4, Lorenzo Fontana wrote:
> > > What's the output of vim --version | grep python ?
> > Some info:
> > python version: 2.7.10
> > vim version: 7.4.712
> > os x yosemite
> >
> > Full output of command:
> > +cryptv +linebreak +python +viminfo
> > +cscope +lispindent -python3 +vreplace
> > Linking: /usr/bin/clang -L. -L/usr/local/lib -L/usr/local/lib -F/usr/local/Frameworks -Wl,-headerpad_max_install_names -o vim -lm -lncurses -liconv -framework Cocoa -fstack-protector -L/System/Library/Perl/5.18/darwin-thread-multi-2level/CORE -lperl -F/usr/local/Cellar/python/2.7.10/Frameworks -framework Python -lruby.2.0.0 -lobjc
>
>
> The error you do something like this, the error appears?
>
> :python print 'Hi!'
Sorry,
If you do something like this, the error appears?
:python print 'Hi!'
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Python load error
> On Friday, July 31, 2015 at 11:58:48 AM UTC-4, Lorenzo Fontana wrote:
> > What's the output of vim --version | grep python ?
> Some info:
> python version: 2.7.10
> vim version: 7.4.712
> os x yosemite
>
> Full output of command:
> +cryptv +linebreak +python +viminfo
> +cscope +lispindent -python3 +vreplace
> Linking: /usr/bin/clang -L. -L/usr/local/lib -L/usr/local/lib -F/usr/local/Frameworks -Wl,-headerpad_max_install_names -o vim -lm -lncurses -liconv -framework Cocoa -fstack-protector -L/System/Library/Perl/5.18/darwin-thread-multi-2level/CORE -lperl -F/usr/local/Cellar/python/2.7.10/Frameworks -framework Python -lruby.2.0.0 -lobjc
The error you do something like this, the error appears?
:python print 'Hi!'
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Python load error
> What's the output of vim --version | grep python ?
Some info:
python version: 2.7.10
vim version: 7.4.712
os x yosemite
Full output of command:
+cryptv +linebreak +python +viminfo
+cscope +lispindent -python3 +vreplace
Linking: /usr/bin/clang -L. -L/usr/local/lib -L/usr/local/lib -F/usr/local/Frameworks -Wl,-headerpad_max_install_names -o vim -lm -lncurses -liconv -framework Cocoa -fstack-protector -L/System/Library/Perl/5.18/darwin-thread-multi-2level/CORE -lperl -F/usr/local/Cellar/python/2.7.10/Frameworks -framework Python -lruby.2.0.0 -lobjc
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Python load error
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Vim commands for copying to system clipboard but text does not show system clipboard
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Vim commands for copying to system clipboard but text does not show system clipboard
On 2015-07-31 18:17, Philip Rhoades wrote:
> Lorenzo,
>
>
> On 2015-07-31 17:59, Lorenzo Fontana wrote:
>> Do you have vim with clipboard support?
>> You can verify this with
>>
>> vim --version | grep clipboard
>
>
> -clipboard +iconv +path_extra -toolbar
> +eval +mouse_dec +startuptime -xterm_clipboard
>
>
> Ah . . it looks like no . . I would have thought that this was an
> essential feature and should be available by default? I use Fedora
> RPMs - does that mean I have to compile Vim myself?
To answer my own question - it looks like I have to use "vimx" from the
vim-X11 RPM instead of the vim from vim-enhanced . .
Thanks,
Phil.
--
Philip Rhoades
PO Box 896
Cowra NSW 2794
Australia
E-mail: phil@pricom.com.au
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Vim commands for copying to system clipboard but text does not show system clipboard
On 2015-07-31 17:59, Lorenzo Fontana wrote:
> Do you have vim with clipboard support?
> You can verify this with
>
> vim --version | grep clipboard
-clipboard +iconv +path_extra -toolbar
+eval +mouse_dec +startuptime -xterm_clipboard
Ah . . it looks like no . . I would have thought that this was an
essential feature and should be available by default? I use Fedora RPMs
- does that mean I have to compile Vim myself?
Thanks,
Phil.
--
Philip Rhoades
PO Box 896
Cowra NSW 2794
Australia
E-mail: phil@pricom.com.au
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Vim commands for copying to system clipboard but text does not show system clipboard
You can verify this with
vim --version | grep clipboard
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Vim commands for copying to system clipboard but text does not show up in Clipman
On 2015-07-31 17:08, Noah Petherbridge wrote:
> The yy command in vim isn't a system clipboard copy/paste... it only
> works within the vim session.
That is not supposed to be the case - "*" and "+" copy to the SYSTEM
clipboard:
http://vim.wikia.com/wiki/Accessing_the_system_clipboard
Phil.
> i.e. after doing the "+yy key combo, move the insertion cursor
> somewhere else and hit "p".. it will paste the line that you were on
> when you hit the copy shortcut.
>
> On 07/30/2015 11:23 PM, Philip Rhoades wrote:
>> People,
>>
>> In Vim, these commands are supposed to copy text to the system
>> clipboard - but the text does not show up in Clipman:
>>
>> "+yy
>>
>> "*yy
>>
>> - why doesn't this work?
>>
>> In fact, rather than copying the current line as above, I want to copy
>> the text of a whole file which is not conveniently done by clicking
>> and dragging the mouse . . but I can't even get it to work on one line
>> . .
>>
>> Thanks,
>>
>> Phil.
--
Philip Rhoades
PO Box 896
Cowra NSW 2794
Australia
E-mail: phil@pricom.com.au
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Thursday, July 30, 2015
Vim commands for copying to system clipboard but text does not show system clipboard
In Vim, these commands are supposed to copy text to the system clipboard
- but the text does not show up in Clipman:
"+yy
"*yy
- why doesn't this work?
I thought maybe it was a problem with xfce4-clipman-plugin so I
uninstalled it but I still can only paste into a browser if I use the
mouse to mark a block of text . .
In fact, rather than copying the current line as above, I want to copy
the text of a whole file which is not conveniently done by clicking and
dragging the mouse . . but I can't even get it to work on one line . .
Thanks,
Phil.
--
Philip Rhoades
PO Box 896
Cowra NSW 2794
Australia
E-mail: phil@pricom.com.au
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Persistent undo and force quit
On Jul 28, 2015 18:31, "David Besen" <dbesen@gmail.com> wrote:
>
> Second draft, seems to work a little better:
>
> "save undo if we qa!
> function! MyWundoQuit()
> let undoseq = undotree().seq_cur
> earlier 1f
> let undof = escape(undofile(expand('%')),'% ')
> exec "wundo " . undof
> silent! exec "u " . undoseq
> endfunction
>
> autocmd BufWinLeave * call MyWundoQuit()
Why does the second draft still have "earlier 1f" ? Why can't you just write the undo file?
----
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Python load error
E887: Sorry, this command is disabled, the Python's site module could not be loaded.
Any ideas what might be causing this?
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Flexible auto-insertion of date at end of file.
> So the first ex command is the :put command (":help :put") with a
Doh! Yes, now it has a place in the jigsaw.
It is very early morning here, too late in the night for coffee.
I'll read up on it tomorrow. Have to fit in a bit of sleep somewhere.
Thanks.
Erik
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Flexible auto-insertion of date at end of file.
> On 30.07.15 07:52, Tim Chase wrote:
> > So combining those above with your enhancement request, I came up
> > with the following function which seems to do what you want:
> >
> > function! Append_Date(fmt)
> > $put=strftime(a:fmt)
> > startinsert!
> > endfunction
>
> Many thanks Tim. That does it exactly, is half the length of what I
> laboriously waded through swamps to cobble together, and doesn't
> have lines which don't work as expected.
>
> I'm sure all my helpgrepping and archive diving was good for my
> soul, but the syntax which works is in a dialect I don't grok.
> Looks like I'll have to try to find out where it fits into the
> normal/ex/whatever universe. One day.
Functions are just a sequence of ex commands. Because of that, the
leading ":" can be omitted, but if present, will just be ignored.
So the first ex command is the :put command (":help :put") with a
specified line/location ("$" is the last line of the file:
":help :$"). The ":put" command expects a register, and as detailed
in the help, if you use the expression register ("="), you can
provide an expression to evaluate...in this case, the results of the
strftime() function.
The second ex command is "startinsert!" which, according to ":help
:startinsert" goes into insert-mode after the function has finished
evaluating. By using the "!", it acts like typing "A" in Normal-mode
to append to the end of the line.
Put those two pieces together, and presto! :-)
-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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Flexible auto-insertion of date at end of file.
> So combining those above with your enhancement request, I came up
> with the following function which seems to do what you want:
>
> function! Append_Date(fmt)
> $put=strftime(a:fmt)
> startinsert!
> endfunction
Many thanks Tim. That does it exactly, is half the length of what I
laboriously waded through swamps to cobble together, and doesn't have
lines which don't work as expected.
I'm sure all my helpgrepping and archive diving was good for my soul,
but the syntax which works is in a dialect I don't grok. Looks like I'll
have to try to find out where it fits into the normal/ex/whatever
universe. One day.
Erik
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Flexible auto-insertion of date at end of file.
> Desired Enhancement:
...
Changing to named parameters fails through lack of an eval/expand on the
a:Format, but then also switching to strange appending syntax¹ ($put)
found on the list:
au BufWinEnter ~/Personal/rainfall/*/* call Append_Date('%d.%m: ')
function! Append_Date(Format)
normal G
" :r !date a:Format " Fails: date: invalid date `a:Format'
$put=strftime(a:Format)
normal A
endfunction
does 99% of the job, appending the date to the file, and moving the
cursor to the end of the inserted text. (I.e. half of the "normal A"
action) It still does not enter insert mode. Replacing that with a:
startinsert
finally does the job. But that took a lot of grepping through mail
archives to find and dissect related old posts. (Tried googling this
stuff, but it was all chaff - no wheat.)
¹ :h $put
E149: Sorry, no help for $put
:helpgrep " put"
E480: No match: " put"
How to find it, I wonder?
Erik
--
Abbott's Admonitions:
(1) If you have to ask, you're not entitled to know.
(2) If you don't like the answer, you shouldn't have asked the question.
- Charles Abbot, dean, University of Virginia
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Flexible auto-insertion of date at end of file.
> function! Append_Date()
> normal G
> :r !date '+\%d.\%m: '
> normal A
> endfunction
You're on the right track. As an aside, you can just specify the
line before the :r command and the ":" is superfluous. To simplify
matters further, vim has its own strftime() function that you can use
instead of shelling out for the date. Finally, after your "normal
A", vim returns to normal mode because you're still in a function.
Fortunately, vim also provides a ":startinsert" command to start
insertion mode.
> Desired Enhancement:
> make the date format a function argument
>
> function! Append_Date()
> normal G
> :r !date a:1
> normal A
> endfunction
So combining those above with your enhancement request, I came up
with the following function which seems to do what you want:
function! Append_Date(fmt)
$put=strftime(a:fmt)
startinsert!
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Is there a repository of spell files for different languages?
Googling i found a link to
<ftp://ftp.vim.org/pub/vim/runtime/spell/> but it seems to be dead.
Even though it turned out to be a piece of cake to build .spl
files once you have gotten hold of an appropriate
OpenOffice/LibreOffice 'dictionary' file maybe it would be a good
idea to create a public repository somewhere. I'm thinking GitHub
because then people can contribute files they created themselves
by doing a pull request. I'd be willing to build .spl files from
existing OO/LO 'dictionaries' and maintain the repository if the
OO/LO licenses permit it and there is an interest.
/bpj
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Flexible auto-insertion of date at end of file.
"Autoinsert date at end of file, _after_ reading modelines:
au BufWinEnter ~/Data/rainfall/*/* call Append_Date()
function! Append_Date()
normal G
:r !date '+\%d.\%m: '
normal A
endfunction
Problem:
The "normal A" moves the cursor to the end of the inserted date, but
does not enter insert mode. (Stays in normal)
Appending a ^V^M to the second line doesn't help.
How should I hold my mouth for the "normal A" to take effect?
Desired Enhancement:
This is ambitious, but if I could make the date format a function
argument, then the one function could serve a multitude of autocommands,
each with an application-specific date format. But *function-argument*
in the help does not overflow with allowable syntax description. This
simple attempt:
au BufWinEnter ~/Personal/rainfall/*/* call Append_Date("'+\%d.\%m: '")
function! Append_Date()
normal G
:r !date a:1
normal A
endfunction
disappointingly gives:
E118: Too many arguments for function: Append_Date
There is presumably some concise (readable|(arcane&cryptic)) way to pass
a simple literal string to a function in an autocommand?
VIM - Vi IMproved 7.4 (2013 Aug 10, compiled Apr 2 2015 20:12:09)
Included patches: 1-688
That's the latest package for debian 7.8.0, very recently installed.
Could take the source path, if that were necessary.
Erik
--
manual, n.:
A unit of documentation. There are always three or more on a given item.
One is on the shelf; someone has the others.
The information you need is in the others. - Ray Simard
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Wednesday, July 29, 2015
Re: Buffer name resolution and simplification
Mmmh, still wrong as cd overrides lcd for the current window.
I know this is vim_use, not vim_abuse, but anyway this is what I did:
0split | lcd . | quit
This will honour whatever the setting of your current window is, while making
the buffer names relative to the effective working directory for that window.
Apparently a small split height (0 in this case) reduces or even eliminates
the visual artifacts. Also, if you put that line after a silent make but
before the redraw, no additional artifacts will show up. True, it's ugly, but
it does the work. A safer, cleaner alternative I can figure out is to modify
errorformat so that getcwd() is left out of %f, but it's tedious as this
should be down for any compiler that potentially spits out an absolute
path.
Cheers
--
Carlos
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Buffer name resolution and simplification
cd | cd -
If you don't want to lose your previous global working directory (I don't care):
try | cd - | catch | cd | endtry | cd -
Cheers
--
Carlos
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Buffer name resolution and simplification
>
> > I've done most of my testing of this by looking at the quickfix
> > list contents and haven't seen any unexpected results.
>
> Until you have a window with :lcd applied, then you may change
> your global working directory to that one ;)
>
> AFAIK there is no safe way to cd to the global working directory.
> Both pwd and getcwd() return the effective working directory
> (local or global).
>
> Calling lcd instead of cd wouldn't be completely right either,
> because you may end up with a local setting where you didn't had
> one.
Good points. Thanks again.
Back to the drawing board.
Regards,
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
---
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Buffer name resolution and simplification
> contents and haven't seen any unexpected results.
Until you have a window with :lcd applied, then you may change your global working directory to that one ;)
AFAIK there is no safe way to cd to the global working directory. Both pwd and getcwd() return the effective working directory (local or global).
Calling lcd instead of cd wouldn't be completely right either, because you may end up with a local setting where you didn't had one.
Cheers
--
Carlos
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Buffer name resolution and simplification
>
> Thank you for the clever hack, Gary. I've not exhaustively tested
> what follows, but it can be an improvement upon your solution in
> two ways:
>
> 1. Some sane filename escaping.
> 2. It makes the path relative in the quickfix list too (earlier
> interception by using BufNew instead of BufAdd):
>
> autocmd BufNew * execute 'cd ' . fnameescape(getcwd())
Thanks. I forgot about the need for fnameescape().
BufNew doesn't seem to be needed to make this apply to the quickfix
list. When a quickfix list is created, a buffer is created for each
file in the list and added to the buffer list, and the buffer number
rather than the file name is saved in the quickfix list. When the
quickfix list is displayed, either by :clist or by :copen, each
buffer number is resolved to the buffer name at that time.
I've done most of my testing of this by looking at the quickfix list
contents and haven't seen any unexpected results.
Regards,
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
---
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Buffer name resolution and simplification
1. Some sane filename escaping.
2. It makes the path relative in the quickfix list too (earlier interception by using BufNew instead of BufAdd):
autocmd BufNew * execute 'cd ' . fnameescape(getcwd())
Cheers
--
Carlos
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: I cannot realise a :map why ??
> For instance I should like to make F9 stand for papa
> Following VIM Manual (by Moolenaar) I type :
> :map <F9> ipapa<Esc> (5 characters for <Esc> and 4 characters for <F5> )
> But it doesn't work. Instead of « papa « , it returns <F9>
> Something is wrong, but where ?? Thanks for your reply.
It is marvellous to find people like you. Your replies are so quick. I think manual is good for mkdir, install, apt-get etc. But for modes I must see elsewhere. Vim is very strong but difficult.
The way I leaved normal mode, for command Line Window , I found it after many trials.
First I type :!(CR) Vim says CR or quit. I type q , and after : There I am. If you know a better way please tell me. Again many 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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: I cannot realise a :map why ??
> Le mardi 21 juillet 2015 10:02:15 UTC+2, aubertin.sylvain a écrit :
> > For instance I should like to make F9 stand for papa
> > Following VIM Manual (by Moolenaar) I type :
> > :map <F9> ipapa<Esc> (5 characters for <Esc> and 4 characters for <F5> )
> > But it doesn't work. Instead of « papa « , it returns <F9>
> > Something is wrong, but where ?? Thanks for your reply.
>
> AT LAST I USED F9 WITH SUCCESS
> 1. I load my shell with « vim shellname »
That means you load a file named "shellname".
> 2 I see my shell. At the bottom (on the left side ) I find the name of my shelL Please What is the name of this mode ? On my text I can delete usimg x or dd. But F9 gives me nothing.
That sounds like normal mode.
> 3 I go to another mode whose name I ignore again. It is in two parts. Above I have the text of my shell and below I have a list which contains ancient commands
That sounds like the command-line window. Did you type "q:"?
> 4 I find my map command and enable it with a CR. List disappears.
Yeah, that's the command-line window.
> 5 I go back to my shell. THIS TIME WHEREVER I AM IT INSERT.S « papa » WITH SUCCESS
> I repeat I do that outside insert mode.
> So map works if it is freshly enabled. I think it is impossible to have a permanent :map
It depends on what you mean by "permanent". If you mean "from one Vim
instance to the next", well, yes that's impossible, but that's also
pretty much what a .vimrc file is used to: to store command you want
executed every time you open Vim.
Now I'm sorry if I'm a bit rude, but judging from your interventions
here I must ask: did you read the ... manual?
Best,
Paul
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Tuesday, July 28, 2015
Re: I cannot realise a :map why ??
> For instance I should like to make F9 stand for papa
> Following VIM Manual (by Moolenaar) I type :
> :map <F9> ipapa<Esc> (5 characters for <Esc> and 4 characters for <F5> )
> But it doesn't work. Instead of « papa « , it returns <F9>
> Something is wrong, but where ?? Thanks for your reply.
AT LAST I USED F9 WITH SUCCESS
1. I load my shell with « vim shellname »
2 I see my shell. At the bottom (on the left side ) I find the name of my shelL Please What is the name of this mode ? On my text I can delete usimg x or dd. But F9 gives me nothing.
3 I go to another mode whose name I ignore again. It is in two parts. Above I have the text of my shell and below I have a list which contains ancient commands
4 I find my map command and enable it with a CR. List disappears.
5 I go back to my shell. THIS TIME WHEREVER I AM IT INSERT.S « papa » WITH SUCCESS
I repeat I do that outside insert mode.
So map works if it is freshly enabled. I think it is impossible to have a permanent :map
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Persistent undo and force quit
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Persistent undo and force quit
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: match() to get the offsets of all matches of a pattern in a string
> I have a string of rows of dashes alternating with spaces,
> where the number of dashes/spaces is variable
>
> ----- ------- --- ----
>
> I want to get a List of the offsets of all the space sequences,
> kind of a match() with /g (that's the best I can do to describe
> it...) In the case above (ignoring the indent, I would get
> [6, 16, 20].
>
> It's the usual problem: I don't know the right :help keyword
>
> /bpj
>
Sorry for the noise. I gave up and did it the traditional way:
let colpos_l = []
let colpos = 0
let str_len = strlen(line)
while colpos < str_len
let colpos = matchend(sepline, '-\+\ze\s', colpos)
if colpos < 0
break
elseif colpos > 0
" call add(colpos_l, colpos)
call add(colpos_l, colpos)
endif
endwhile
I will make a 'plugin' of a generalized version of this though...
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
match() to get the offsets of all matches of a pattern in a string
where the number of dashes/spaces is variable
----- ------- --- ----
I want to get a List of the offsets of all the space sequences,
kind of a match() with /g (that's the best I can do to describe
it...) In the case above (ignoring the indent, I would get
[6, 16, 20].
It's the usual problem: I don't know the right :help keyword
/bpj
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Monday, July 27, 2015
Re: Recursively open all folds within a range of lines?
|On 2015-07-23 19:26, Paul wrote:
|> Is there a way in vim to recursively open all folds within a range
|> of lines? The zO command will open all folds in the entire file,
|> but I don't want that.
|
| Depending on whether you want to ignore or suppress error messages,
| you can use
|
| :3,15norm zO
|
| or
|
| :sil! 3,15norm zO
|
| where "3,15" is the range over which you want to open folds (any
| range will do: ":help :range").
|
| If any of the lines in that range aren't part of a fold, it will
| give an error message ("E490: No fold found") so prefixing it with
| the "sil!" is a nice way to tell it to shut up about stuff you don't
| care about.
|
| If you do it frequently, you can make a :command or :map it.
Thanks, Tim. It works like a "bewt". I may map it later, but for the
time being, I don't want to go throught anx of what mapping to give
up.
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Buffer name resolution and simplification
> When I open a file in the current working directory by specifying
> just the relative file name, that short, relative file name appears
> in the status line and in the buffer list. When I open another file
> in the same directory by specifying the full path name, that full
> path name is used in the status line and in the buffer list.
> Is there a way to force Vim to always display the file name as a
> relative path name, if it can?
I have a fix/workaround that seems to work:
au BufAdd * exe "cd" getcwd()
Regards,
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
---
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Persistent undo and force quit
On Mo, 20 Jul 2015, David Besen wrote:
> I have persistent undo turned on. I noticed this behavior:
>
> - If I edit a file, make a change and don't save it, execute :qall!, edit the
> file again, and try to redo, the change is gone.
>
> - If I edit a file, make a change, undo it, save the file (essentially making
> no change to the file on disk), quit, edit the file again, and try to redo, the
> change is made! The undo tree was saved even though there was no change to the
> file.
>
> I would like to get vim to save the undo history even if I make an edit and
> then execute :qall!. Is there any way to do that?
undo files are only written, when the buffer is written. If you abort
editing, there is no reason to write something.
My guess is, it is avoided to make aborting work faster
since for writing the undo file, a hash of the buffer has to be
calculated and then the undo file needs to be written, which also might
take some time.
Now imagine several large buffers and a slow network file system.
You could possibly script something using the mentioned wundo command
and a VimLeave autocommand.
Best,
Christian
--
Eine Million Steuerzahler verhalten sich vernünftiger als eine
öffentliche Hand.
-- Hermann Josef Abs
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: gvim search and replace
> Hi,
>
> I am new to gvim editor. Needed a small help regarding gvim search and replace.
>
> I needed to search and replace as:-
>
> AIO_P71_TSD0_CTRL with AIO_PRI_TSD0_CTRL
> AIO_P71_TSD1_CTRL with AIO_PRI_TSD1_CTRL
> AIO_P71_TSD2_CTRL with AIO_PRI_TSD2_CTRL
>
> I tried the below:-
>
> >s/AIO_P71_TSD\.*_CTRL/AIO_PRI_TSD\0_PRI_CTRL/g
Hmm, wouldn't just
:%s/P71/PRI/c
do the job?
Elimar
--
.~.
/V\ L I N U X
/( )\ >Phear the Penguin<
^^-^^
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: dbext.vim bug: jumplist pollution caused by BufRead handler
dbext's BufRead handler (and maybe others) adds a spurious mark at
line 1 of each buffer. This is very annoying. Steps to reproduce:
:h h
:h a
<c-o>
The <c-o> step will go to the top of the file instead of the previous
":h h" location. Another <c-o> will then go to the ":h h" location.
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: gvim search and replace
> On 2015-07-27 04:05, Melvin Simon wrote:
> > Hi,
> >
> > I am new to gvim editor. Needed a small help regarding gvim search
> > and replace.
> >
> > I needed to search and replace as:-
> >
> > AIO_P71_TSD0_CTRL with AIO_PRI_TSD0_CTRL
> > AIO_P71_TSD1_CTRL with AIO_PRI_TSD1_CTRL
> > AIO_P71_TSD2_CTRL with AIO_PRI_TSD2_CTRL
> >
> > I tried the below:-
> >
> > >s/AIO_P71_TSD\.*_CTRL/AIO_PRI_TSD\0_PRI_CTRL/g
> >
> > i.e. I was guessing \0 would print the characters (here 0,1,2)
> > matched by .* however looks like its matching the entire word. Can
> > some one tell me how to accomplish the above search and replace.
>
> You're close. Try
>
> :%s/AIO_\zsP71\ze_TSD.*_CTRL/PRI/g
>
> You can read up about \zs and \ze at
>
> :help /\zs
> :help /\ze
>
> -tim
Thank you Tim! Perfect!
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: gvim search and replace
> Hi,
>
> I am new to gvim editor. Needed a small help regarding gvim search
> and replace.
>
> I needed to search and replace as:-
>
> AIO_P71_TSD0_CTRL with AIO_PRI_TSD0_CTRL
> AIO_P71_TSD1_CTRL with AIO_PRI_TSD1_CTRL
> AIO_P71_TSD2_CTRL with AIO_PRI_TSD2_CTRL
>
> I tried the below:-
>
> >s/AIO_P71_TSD\.*_CTRL/AIO_PRI_TSD\0_PRI_CTRL/g
>
> i.e. I was guessing \0 would print the characters (here 0,1,2)
> matched by .* however looks like its matching the entire word. Can
> some one tell me how to accomplish the above search and replace.
You're close. Try
:%s/AIO_\zsP71\ze_TSD.*_CTRL/PRI/g
You can read up about \zs and \ze at
:help /\zs
:help /\ze
-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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Custom command completion
I am trying to write a plugin, where the `b:Sdir` will take the directories with source code. I am trying to achieve autocompletion as:
"MakeMake: Generate Makefile.gen
function! MakeMake()
let b:Rdir = input("Project root folder: ", ".", 'file')
exe ":lchdir ".b:Rdir
" More than 1 files can be choosed
let b:Sdir = input("Choose source dir: ", ".", "customlist,CFile")
endfunction
function! CFile(A,L,P)
return split(globpath(b:Rdir, a:A),"\n")
endfunction
But this is not working.
As normal, if I use "split(globpath(b:Rdir, "*"),"\n")" in CFile, it will show ALL files in the directory available, but not filter the files.
How can I achieve completion for this?
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
gvim search and replace
I am new to gvim editor. Needed a small help regarding gvim search and replace.
I needed to search and replace as:-
AIO_P71_TSD0_CTRL with AIO_PRI_TSD0_CTRL
AIO_P71_TSD1_CTRL with AIO_PRI_TSD1_CTRL
AIO_P71_TSD2_CTRL with AIO_PRI_TSD2_CTRL
I tried the below:-
>s/AIO_P71_TSD\.*_CTRL/AIO_PRI_TSD\0_PRI_CTRL/g
i.e. I was guessing \0 would print the characters (here 0,1,2) matched by .* however looks like its matching the entire word. Can some one tell me how to accomplish the above search and replace.
Thanks in advance
Melvin
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: There is a mistake in my « makefile »
:set list
:set listchars+=tab:>.
Makes visible the crucial tab character that makefiles must have at the beginning of command lines. You can put these two lines in
$HOME/.vim/after/ftplugin/make.vim
to have them invoked automatically.
Regards, John Little
--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Sunday, July 26, 2015
Re: There is a mistake in my « makefile »
> Le vendredi 24 juillet 2015 07:59:40 UTC+2, aubertin.sylvain a écrit :
> > I am a beginner, in vim. Something is wrong in my makefile. At the end of my shell, when I type :make it works well. All my shell is compiled. But no trace of the object file, named essai.o
> > My source file is essai. Somewhere « make » or « /bin/bash » says to me : cyclic permutation is no correct. That is something I don't understand.
> > I should like to save my object file. Shall I use « sudo make install » or « sudo essai.o install » ? ?
> > For installing must I use commands put inside the makefile or am I forced to do that in second time, out of my makefile ? ? Here is my makefile :
> > # indiquer quel compilateur utiliser
> > #!/bin/bash
> > #makefile
> > all: essai.o
> > essai.o: essai
> > /bin/bash essai -o essai.o
> > My OS is : xubuntu 14.4.1 My vim version is 7.4. 52 My PC is hp Mini 110 1100
> > THANKS A LOT TO ALL MY REPLIERS
> I do all that in order to learn how it works. Compiling shells is
> good for the secrets. Please,if you know well makefiles, tell me
> if this one seems good to you. I'll try that once I installed my
> shell compiler.
> #makefile
> all: essai.o
> essai.o: essai
> compiler essai essai.o
This has nothing to do with Vim.
The compiler command and the makefile rules are going to depend on
the compiler. For shc, for example, you specify only the script
file name and the compiler creates a binary file and a C source file
whose names are derived from the script file name. You can probably
override the default binary file name, but I'll leave that for you
to discover.
Rather than ask further off-topic questions here, you can get better
answers by searching the Internet for "bash compiler" and "make
tutorial".
Regards,
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
---
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: There is a mistake in my « makefile »
On Jul 27, 2015 12:49 AM, "aubertin.sylvain" <aubertin.sylvain@sfr.fr> wrote:
>
> Le vendredi 24 juillet 2015 07:59:40 UTC+2, aubertin.sylvain a écrit :
> > I am a beginner, in vim. Something is wrong in my makefile. At the end of my shell, when I type :make it works well. All my shell is compiled. But no trace of the object file, named essai.o
> > My source file is essai. Somewhere « make » or « /bin/bash » says to me : cyclic permutation is no correct. That is something I don't understand.
> > I should like to save my object file. Shall I use « sudo make install » or « sudo essai.o install » ? ?
> > For installing must I use commands put inside the makefile or am I forced to do that in second time, out of my makefile ? ? Here is my makefile :
> > # indiquer quel compilateur utiliser
> > #!/bin/bash
> > #makefile
> > all: essai.o
> > essai.o: essai
> > /bin/bash essai -o essai.o
> > My OS is : xubuntu 14.4.1 My vim version is 7.4. 52 My PC is hp Mini 110 1100
> > THANKS A LOT TO ALL MY REPLIERS
> I do all that in order to learn how it works. Compiling shells is good for the secrets. Please,if you know well makefiles, tell me if this one seems good to you. I'll try that once I installed my shell compiler.
> #makefile
> all: essai.o
> essai.o: essai
> compiler essai essai.o
> MANY THANKS
The web page whose address you posted was clear about how to invoke shc. Please refer back to it, and then try the command in the shell (and by that I mean *not* inside of Vim or in a makefile) until you're comfortable with how it works.
Then see if you can apply that knowledge in a makefile. You have a good start already; but you might want to consult a makefile tutorial.
When you have it working so you can just type `make` on the command line, the :make command in Vim should also work. This really is all about general commands line/shell usage and not about Vim at all.
----
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Buffer name resolution and simplification
just the relative file name, that short, relative file name appears
in the status line and in the buffer list. When I open another file
in the same directory by specifying the full path name, that full
path name is used in the status line and in the buffer list. Here
is an example using the Vim source directory.
$ cd vim/src
$ vim
:e os_beos.c
:e /usr/local/src/vim-7.4/vim/src/os_unix.c
:ls
1 # "os_beos.c" line 1
2 %a "/usr/local/src/vim-7.4/vim/src/os_unix.c" line 1
If I then change the working directory, Vim resolves/simplifies both
file names to relative path names.
:cd ..
:ls
1 # "src/os_beos.c" line 1
2 %a "src/os_unix.c" line 1
Is there a way to force Vim to always display the file name as a
relative path name, if it can?
The reason I ask is that I open files by a variety of methods so
that the buffer list and the quickfix list wind up with a mixture of
relative and absolute path names. It would make it easier for me to
recognize files that are in the same directory if all the names in
or below the current working directory were shown as relative path
names.
Regards,
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
---
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: There is a mistake in my « makefile »
> I am a beginner, in vim. Something is wrong in my makefile. At the end of my shell, when I type :make it works well. All my shell is compiled. But no trace of the object file, named essai.o
> My source file is essai. Somewhere « make » or « /bin/bash » says to me : cyclic permutation is no correct. That is something I don't understand.
> I should like to save my object file. Shall I use « sudo make install » or « sudo essai.o install » ? ?
> For installing must I use commands put inside the makefile or am I forced to do that in second time, out of my makefile ? ? Here is my makefile :
> # indiquer quel compilateur utiliser
> #!/bin/bash
> #makefile
> all: essai.o
> essai.o: essai
> /bin/bash essai -o essai.o
> My OS is : xubuntu 14.4.1 My vim version is 7.4. 52 My PC is hp Mini 110 1100
> THANKS A LOT TO ALL MY REPLIERS
I do all that in order to learn how it works. Compiling shells is good for the secrets. Please,if you know well makefiles, tell me if this one seems good to you. I'll try that once I installed my shell compiler.
#makefile
all: essai.o
essai.o: essai
compiler essai essai.o
MANY 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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.