Skip to search.

Breaking News Visit Yahoo! News for the latest.

×Close this window

vim · Vim (Vi IMproved) text editor users list

The Yahoo! Groups Product Blog

Check it out!

Group Information

? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Real people. Real stories. See how Yahoo! Groups impacts members worldwide.

Messages

Advanced
Messages Help
Messages 136763 - 136792 of 137773   Oldest  |  < Older  |  Newer >  |  Newest
Messages: Show Message Summaries Sort by Date ^  
#136763 From: Gary Johnson <garyjohn@...>
Date: Fri Mar 15, 2013 7:29 pm
Subject: Setting cedit=<Esc> causes vimincr :I to fail
garyjohn@...
Send Email Send Email
 
I've been having a problem using Dr. Chip's visincr plugin that I
finally tracked down to this setting in my ~/.vimrc:

     set cedit=<Esc>

With that setting, using :I on the example in ":help visincr-usage"
results in changing this

ORIG
+---+
| 8 |
| 8 |
| 8 |
| 8 |
+---+

to this

ORIG
+---+
8  8 |
9  8 |
10 8 |
11 8 |
+---+

with the incremented numbers moved to the left instead of replacing
the original column of 8s.

I further discovered that the problem occurs when one of these two
lines in autoload/visincr.vim is executed:

     645      exe 'norm! /\%'.leftcol."v\<Esc>"
     677       exe 'norm! /\%'.bkup."v\<Esc>"

I can solve the problem by surrounding that part of the code in
visincr#VisBlockIncr() with

     let l:cedit = &cedit
     set cedit&

and

     let &cedit = l:cedit

which is what I recommend Dr. Chip do, but it bothers me that
"norm!" was not sufficient to prevent my setting of 'cedit' from
corrupting his use of "<Esc>".

Should the function of "!" in :normal and of "nore" in mappings be
extended to also ignore any non-default settings of 'cedit'?

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/groups/opt_out.

#136764 From: John Little <John.B.Little@...>
Date: Fri Mar 15, 2013 8:47 pm
Subject: Why is Vimscript/VimL much slower than Python when traversing long lists?
John.B.Little@...
Send Email Send Email
 
Well, I know squat about Python but I presume it has a compilation phase like
Perl, which compiles to "op codes" which are executed without, f. ex., variable
look ups. Vim uses a pure interpreter.

Vim script is "fast enough", and has the virtue of running anywhere vim does
(well, not quite; anywhere a "normal" non-gui build does) with few dependencies,
IIUC a C compiler and the standard library.

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/groups/opt_out.

#136765 From: Ben Fritz <fritzophrenic@...>
Date: Fri Mar 15, 2013 8:58 pm
Subject: Re: gVim: Non-breaking space strangely triggers :simalt~
fritzophrenic@...
Send Email Send Email
 
On Friday, March 15, 2013 11:51:08 AM UTC-5, Sylvia Ganush wrote:
> Thanks for your tip, Ben, but setting 'winaltkeys=no' has made no difference.
>
>
>
> There's another space-related anomaly that I suspect may shed light on my
issue. One keymapping has stopped working. I have 'noremap <leader><space>
:noh<cr>' in my _vimrc, but instead of suppressing search highlighting it pauses
for a second and then moves the cursor one character to the right.
>
>
>
> Do you think this gives us a clue?
>
>

Please bottom post.

I doubt these two issues are related.

Your new issue is probably one of these:

1. something has undefined your mapping
2. you have a space character in your _vimrc file at the end of the line after
your mapping definition

In insert mode there is a 3rd option, but in your case this is a normal mode
mapping so it doesn't apply:
3. you have 'paste' set so mappings don't apply

For your original issue, what mode are you in when you try to use this
autohotkey script? Why do you expect it to "paste" something? Can you still get
this issue to occur? You said it only affects one instance of Vim and the rest
are fine.

I don't know anything at all about autohotkey so I can't debug that side. But
Vim shouldn't show the menu unless it actually gets an alt keypress, and then it
shouldn't show the menu at all if 'winaltkeys' is set to "no".

--
--
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/groups/opt_out.

#136766 From: FlashBurn <rail.shafigulin@...>
Date: Fri Mar 15, 2013 9:10 pm
Subject: vim, cscope and jump stack
rail.shafigulin@...
Send Email Send Email
 
Does anybody know if vim has the ability to store a history of my cscope
searches?It would be nice if I could jump back to my previous searches or to the
files which I jumped from.

Any help is appreciated.

--
--
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/groups/opt_out.

#136767 From: FlashBurn <rail.shafigulin@...>
Date: Fri Mar 15, 2013 9:29 pm
Subject: make vim remember where I left
rail.shafigulin@...
Send Email Send Email
 
Like most of us I open plenty of files at the same time with vim. The problem is
that whenever I go from file 1 to file 2 and then back to file 1, Vim doesn't
remember where I left off. It opens the file and puts the cursor on line 1. Is
there a way to make it remember to put the cursor where I left off?
Any help is appreciated.

--
--
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/groups/opt_out.

#136768 From: Phil Dobbin <phildobbin@...>
Date: Fri Mar 15, 2013 9:33 pm
Subject: Re: make vim remember where I left
phildobbin@...
Send Email Send Email
 
On 15/03/2013 21:29, FlashBurn wrote:

> Like most of us I open plenty of files at the same time with vim. The problem
is that whenever I go from file 1 to file 2 and then back to file 1, Vim doesn't
remember where I left off. It opens the file and puts the cursor on line 1. Is
there a way to make it remember to put the cursor where I left off?
> Any help is appreciated.
>

Try this in your vimrc:

autocmd BufReadPost *
	 \ if line("'\"") > 0 && line("'\"") <= line("$") |
	 \  exe "normal g`\"" |
	 \  endif

Cheers,

   Phil...

--
--
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/groups/opt_out.

#136769 From: Vlad Irnov <vlad.irnov@...>
Date: Fri Mar 15, 2013 9:56 pm
Subject: Re: Why is Vimscript/VimL much slower than Python when traversing long lists?
vlad.irnov@...
Send Email Send Email
 
On 3/15/13, John Little <John.B.Little@...> wrote:
> Well, I know squat about Python but I presume it has a compilation phase
> like Perl, which compiles to "op codes" which are executed without, f. ex.,
> variable look ups. Vim uses a pure interpreter.
>
> Vim script is "fast enough", and has the virtue of running anywhere vim does
> (well, not quite; anywhere a "normal" non-gui build does) with few
> dependencies, IIUC a C compiler and the standard library.
>
> Regards, John Little
>

You are probably right. Python does compile the source code into
bytecode. It's interesting that such basic operation as "for" loop
gets >30-fold performance boost.

Regards,
Vlad

--
--
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/groups/opt_out.

#136770 From: Gary Johnson <garyjohn@...>
Date: Fri Mar 15, 2013 9:58 pm
Subject: Re: vim, cscope and jump stack
garyjohn@...
Send Email Send Email
 
On 2013-03-15, FlashBurn wrote:
> Does anybody know if vim has the ability to store a history of my
> cscope searches?It would be nice if I could jump back to my
> previous searches or to the files which I jumped from.
>
> Any help is appreciated.

As long as you don't exit Vim, the results of the last 10 quickfix
searches will be kept in a stack.  See

     :help quickfix-error-lists

You can move through the stack with :colder and :cnewer and when
you've reached the desired one, you can jump to the current error in
that list with :cc.

Unfortunately, you can't determine what generated each list, so you
have to remember what you put on the stack.

I don't know of any way to save the quickfix stack between Vim
sessions.

You can jump back in the list of places you've been with Ctrl-O.
See

     :help jumplist

HTH,
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/groups/opt_out.

#136771 From: Salman Halim <salmanhalim@...>
Date: Fri Mar 15, 2013 10:11 pm
Subject: Re: Why is Vimscript/VimL much slower than Python when traversing long lists?
salmanhalim@...
Send Email Send Email
 


On Friday, March 15, 2013, Vlad Irnov wrote:
On 3/15/13, John Little <John.B.Little@...> wrote:
> Well, I know squat about Python but I presume it has a compilation phase
> like Perl, which compiles to "op codes" which are executed without, f. ex.,
> variable look ups. Vim uses a pure interpreter.
>
> Vim script is "fast enough", and has the virtue of running anywhere vim does
> (well, not quite; anywhere a "normal" non-gui build does) with few
> dependencies, IIUC a C compiler and the standard library.
>
> Regards, John Little
>

You are probably right. Python does compile the source code into
bytecode. It's interesting that such basic operation as "for" loop
gets >30-fold performance boost.

Regards,
Vlad

--
--
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/groups/opt_out.


It's entirely possible that the loop in question was simply left out as a compiler optimization. Modern compilers can detect no-op loops and unchanging assignments and take these things out of the compiled code. 

Salman 


--
سلمان حلیم

--
--
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/groups/opt_out.
 
 

#136772 From: Sylvia Ganush <sganush@...>
Date: Fri Mar 15, 2013 10:22 pm
Subject: Re: gVim: Non-breaking space strangely triggers :simalt~
sganush@...
Send Email Send Email
 
On 15 Mar 2013, at 21:58, Ben Fritz <fritzophrenic@...> wrote:

> I doubt these two issues are related.

You are right. The broken mapping was just a question of a misplaced space
character. Sorry for the wrong clue.

> For your original issue, what mode are you in when you try to use this
autohotkey script?

Insert mode.

> Why do you expect it to "paste" something?

Well, that's what Autohotkey does. 'Paste' must be a wrong word, though. Let's
say, Autohotkey 'injects' a string. You type a hotstring followed by a trigger
character and it expands it. In my case the hotstring 'excl'-Space should be
expanded to ' !'. gVim stumbles at the nonbreaking space that precedes the
exclamation mark and fires ':simalt ~' instead. This equals to Alt-Space which
brings up the window's title bar menu, the one with 'Restore, Move, Size...'
commands. I hit Escape, the script resumes and enters '!' only.

> Can you still get this issue to occur? You said it only affects one instance
of Vim and the rest are fine.

Yes, and this is odd. I have one gVim session with three tabs and several
windows where the issue is present. Then I open another instance of gVim and
it's fine. But if I open the same tabs and windows in that trouble-free new
instance and save it as a session, the issue reappears.

> I don't know anything at all about autohotkey so I can't debug that side. But
Vim shouldn't show the menu unless it actually gets an alt keypress, and then it
shouldn't show the menu at all if 'winaltkeys' is set to "no".

After some research I was prepared to believe that one can't marry Autohotkey to
gVim as far as entry of special characters is concerned because their ways of
doing it were different. I thought that Autohotkey used something like
'Alt-0160' whereas gVim expected Ctrl-K-Space-Space. But it does work in a
virgin session! Why, oh why?

--
--
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/groups/opt_out.

#136773 From: Sylvia Ganush <sganush@...>
Date: Sat Mar 16, 2013 8:21 am
Subject: Re: gVim: Non-breaking space strangely triggers :simalt~
sganush@...
Send Email Send Email
 
On 15 Mar 2013, at 21:58, Ben Fritz <fritzophrenic@...> wrote:

> Can you still get this issue to occur? You said it only affects one instance
of Vim and the rest are fine.

I think I've tracked the bug. I've compared the 'ill' and 'healthy' gVim
sessions and spotted the offending lines:

Ill session             Healthy session
====================    ====================
cnoremap      :simalt ~    cnoremap      :simalt ~
inoremap      :simalt ~     inoremap      :simalt ~
cnoremap    :simalt ~    ...
inoremap    :simalt ~     ...
noremap     :simalt ~     noremap     :simalt ~
noremap  Â :simalt ~     ...

It's those lines with 'Â' that were giving me the trouble. I've removed them
from the ill session, and things are good again. Now the questions remain, of
course, what those lines mean, where they came from, and how to prevent them
from reappearing.

I have the following two lines in my _vimrc that I think have something to do
with 'simalt':

au GUIEnter * simalt ~x        "Maximize the window on startup
source $VIMRUNTIME/mswin.vim   "Enable Windows-style copypasting

Can they be the culprit?

--
--
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/groups/opt_out.

#136774 From: Christian Brabandt <cblists@...>
Date: Sat Mar 16, 2013 12:10 pm
Subject: Re: vim, cscope and jump stack
cblists@...
Send Email Send Email
 
Hi Gary!

On Fr, 15 Mär 2013, Gary Johnson wrote:

> Unfortunately, you can't determine what generated each list, so you
> have to remember what you put on the stack.

Recent vim versions store that info in the w:quickfix_title variable.

regards,
Christian
--
Treffen sich zwei Berliner. Sagt der eine:
"Mensch! Hab ick doch am letzten Sonntag 100 Mark beim Rennen verloren!"
"Na, wat rennst auch so?!"

--
--
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/groups/opt_out.

#136775 From: Ben Fritz <fritzophrenic@...>
Date: Sat Mar 16, 2013 4:49 pm
Subject: Re: gVim: Non-breaking space strangely triggers :simalt~
fritzophrenic@...
Send Email Send Email
 
On Saturday, March 16, 2013 3:21:10 AM UTC-5, Sylvia Ganush wrote:
> On 15 Mar 2013, at 21:58, Ben Fritz <fritzophrenic@...> wrote:
>
>
>
> > Can you still get this issue to occur? You said it only affects one instance
of Vim and the rest are fine.
>
>
>
> I think I've tracked the bug. I've compared the 'ill' and 'healthy' gVim
sessions and spotted the offending lines:
>
>
>
> Ill session             Healthy session
>
> ====================    ====================
>
> cnoremap      :simalt ~    cnoremap      :simalt ~
>
> inoremap      :simalt ~     inoremap      :simalt ~
>
> cnoremap    :simalt ~    ...
>
> inoremap    :simalt ~     ...
>
> noremap     :simalt ~     noremap     :simalt ~
>
> noremap  Â :simalt ~     ...
>
>
>
> It's those lines with 'Â' that were giving me the trouble. I've removed them
from the ill session, and things are good again. Now the questions remain, of
course, what those lines mean, where they came from, and how to prevent them
from reappearing.
>
>
>
> I have the following two lines in my _vimrc that I think have something to do
with 'simalt':
>
>
>
> au GUIEnter * simalt ~x        "Maximize the window on startup
>
> source $VIMRUNTIME/mswin.vim   "Enable Windows-style copypasting
>
>
>
> Can they be the culprit?

Yes, they can. I'm not sure what exact mapping is interfering. If you think
you've found the mapping, try (for example):

:verbose map Â
:verbose map! Â

This should tell you any existing mappings starting with 'Â' and also what file
defined them. Then it should be pretty easy to remove from that file.

I don't actually think Vim will properly process an ALT+Number keycode though,
if that's what your autohotkeys script is sending, unless you define your own
mapping for it. Try it manually. If it doesn't work, then something like:

   :inoremap <A-1><A-2><A-3><A-4> TextToInsert

should work, but it will require a mapping for every such key sequence.

It sounds like autohotkey is sending an Alt+Space keysequence to Vim, and
naturally Vim responds by brining up the menu as if you had manually typed
Alt+Space explicitly.

--
--
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/groups/opt_out.

#136776 From: Benjamin Klein <ben@...>
Date: Sat Mar 16, 2013 5:30 pm
Subject: How to get rid of oddly-highlighted keywords in Vim
ben@...
Send Email Send Email
 
For what it's worth, I am using Vim for a Grails project, written in Groovy, and I have the Groovy plugin[1] installed. There are certain keywords (“delete” is one) that for some reason are highlighted in red wherever they occur in my source files. What might be the reason for this? I don't think it's the Groovy plugin, because this was occurring back before I had it installed. Also: How might I get rid of this highlighting?


--
b

--
--
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/groups/opt_out.
 
 

#136777 From: Thiago Padilha <tpadilha84@...>
Date: Sat Mar 16, 2013 5:44 pm
Subject: Save all buffers on SIGTERM
tpadilha84@...
Send Email Send Email
 
Is it possible to configure vim to write all buffers when it receives
SIGTERM? I use vim inside multiple  tmux sessions and sometimes I
forget to save something so when I shutdown the computer and reboot
there's a bunch of .swp files around(I would rather have vim save
everything)

I already tried the autowriteall option but it only works when exiting
vim cleanly

--
--
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/groups/opt_out.

#136778 From: Gary Johnson <garyjohn@...>
Date: Sat Mar 16, 2013 8:38 pm
Subject: Re: vim, cscope and jump stack
garyjohn@...
Send Email Send Email
 
On 2013-03-16, Christian Brabandt wrote:
> Hi Gary!
>
> On Fr, 15 Mär 2013, Gary Johnson wrote:
>
> > Unfortunately, you can't determine what generated each list, so you
> > have to remember what you put on the stack.
>
> Recent vim versions store that info in the w:quickfix_title variable.

Cool!  One can learn a lot here by giving wrong answers.  I hardly
ever open the quickfix window because it hasn't been that useful to
me.  Now I'll use it more.

Thanks,
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/groups/opt_out.

#136779 From: Tony Mechelynck <antoine.mechelynck@...>
Date: Sun Mar 17, 2013 6:43 am
Subject: Re: vim, cscope and jump stack
antoine.mechelynck@...
Send Email Send Email
 
On 15/03/13 22:10, FlashBurn wrote:
> Does anybody know if vim has the ability to store a history of my cscope
searches?It would be nice if I could jump back to my previous searches or to the
files which I jumped from.
>
> Any help is appreciated.
>

cscope can produce a "quickfix list", y'know, like :helpgrep, :vimgrep,
:grep and :make do. It can even produce a "location list" (i.e., a
window-local quickfix list).

See
	 :help csqf
	 :help :cscope
	 :help :lcscope
	 :help if_cscop.txt
	 :help quickfix.txt


Best regards,
Tony.
--
This is an especially good time for you vacationers who plan to fly,
because the Reagan administration, as part of the same policy under
which it recently sold Yellowstone National Park to Wayne Newton, has
"deregulated" the airline industry.  What this means for you, the
consumer, is that the airlines are no longer required to follow any
rules whatsoever.  They can show snuff movies.  They can charge for
oxygen.  They can hire pilots right out of Vending Machine Refill
Person School.  They can conserve fuel by ejecting husky passengers
over water.  They can ram competing planes in mid-air.  These
innovations have resulted in tremendous cost savings which have been
passed along to you, the consumer, in the form of flights with
amazingly low fares, such as $29.  Of course, certain restrictions do
apply, the main one being that all these flights take you to Newark,
and you must pay thousands of dollars if you want to fly back out.
		 -- Dave Barry, "Iowa -- Land of Secure Vacations"

--
--
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/groups/opt_out.

#136780 From: Tony Mechelynck <antoine.mechelynck@...>
Date: Sun Mar 17, 2013 7:09 am
Subject: Re: Save all buffers on SIGTERM
antoine.mechelynck@...
Send Email Send Email
 
On 16/03/13 18:44, Thiago Padilha wrote:
> Is it possible to configure vim to write all buffers when it receives
> SIGTERM? I use vim inside multiple  tmux sessions and sometimes I
> forget to save something so when I shutdown the computer and reboot
> there's a bunch of .swp files around(I would rather have vim save
> everything)
>
> I already tried the autowriteall option but it only works when exiting
> vim cleanly
>

Maybe this? (untested)

	 " save everything if terminated by an interceptible signal
	 :aucmd VimLeave * if v:dying | wall | endif

or this?

	 " delete swapfile if the swapped file is 'nomodified'
	 :au SwapExists * if !&mod | let v:swapchoice = 'd' | endif


Best regards,
Tony.
--
BEDEVERE: Stand by for attack!!
     [CUT TO enormous army forming up.  Trebuchets, rows of PIKEMEN, siege
     towers, pennants flying, shouts of "Stand by for attack!"  Traditional
     army build-up shots.  The shouts echo across the ranks of the army.
     We see various groups reacting, and stirring themselves in readiness.]
ARTHUR:   Who are they?
BEDEVERE: Oh, just some friends!
                   "Monty Python and the Holy Grail" PYTHON (MONTY)
PICTURES LTD

--
--
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/groups/opt_out.

#136781 From: Vlad Irnov <vlad.irnov@...>
Date: Mon Mar 18, 2013 9:54 am
Subject: Re: Why is Vimscript/VimL much slower than Python when traversing long lists?
vlad.irnov@...
Send Email Send Email
 
On 3/15/13, Salman Halim <salmanhalim@...> wrote:
...
> It's entirely possible that the loop in question was simply left out as a
> compiler optimization. Modern compilers can detect no-op loops and
> unchanging assignments and take these things out of the compiled code.
>
> Salman
>
>
> --
> سلمان حلیم

This is not the case here. It's easy to check that the time it takes to
run the no-op Python loop is proportional to the number of steps, which
means it is not skipped:

let start = reltime()
python for i in range(10000000): pass
echo reltimestr(reltime(start))
let start = reltime()
python for i in range(100000): pass
echo reltimestr(reltime(start))

I also tried adding some code to the body of each loop in my first
example and still got about 30-fold difference.

Regards,
Vlad

--
--
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/groups/opt_out.

#136782 From: Vlad Irnov <vlad.irnov@...>
Date: Mon Mar 18, 2013 10:16 am
Subject: Re: Why is Vimscript/VimL much slower than Python when traversing long lists?
vlad.irnov@...
Send Email Send Email
 
On 3/15/13, Marc Weber <marco-oweber@...> wrote:
> VimL is known to be slow.

Saying that VimL is slow is pointless without explaining exactly what is
slow(er) and by how much. I am not aware of any actual comparisons of
VimL performance vs other scripting languages. My own conclusion from
very few crude tests is that VimL can be much slower than Python when
dealing with long lists and strings, 20 to 100 times slower. In terms of
actual execution times this only begins to matter with sizes >100000
items. Using map(), filter(), etc. instead of "for" loop help somewhat.
Not everything is slow, :g/pattern/... is fast.


> If you know that you need speed use python or external tools.
>
> Why is it the way it is? I don't know.
>
> Eventually wait for better replies.
>
> I can recommend using a disnict .py file for writing python because then
> you get all python support (syntax, completion, etc).
>
> If you want to learn how a .py file can be found by path have a look at
> github.com/MarcWeber/scion-backend-vim
>
> let s:self=expand('<sfile>:h')

I use Python a lot in my VOoM plugin. You are absolutely right that any
substantial Python code should be in distinct .py files instead of
inside .vim files.


> You may also want to use a str quoting function like this:
>
>   def vimQuote(s):
>     return '"%s"' % s.replace("\\","\\\\").replace('"', '\\"').replace("\n",
> "\\n")
>
> because python's to str comes only close (maybe I should retry the to
> json implementation and find out when whether it fails)
>
> Marc Weber

I usually do
     "'%s'" % s.replace("'","''")

Regards,
Vlad

--
--
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/groups/opt_out.

#136783 From: Hwee-Boon Yar <hweeboon@...>
Date: Mon Mar 18, 2013 10:04 am
Subject: "Focus mode" plugin that only shows one function in a buffer?
hweeboon@...
Send Email Send Email
 
Is there a plugin or way for me to just display and edit a single function in a
buffer? I'm been using MacVim for a few years now and have been mostly working
with ObjC, Python and Ruby which all has the concept of a function. Lately I've
been yearning for a way (from my Smalltalk roots[1]) to just view and edit just
a single function in a buffer, a sort of reverse-folding.

Is there a way to achieve this? Thanks

[1] For those familiar with Smalltalk, when you click on a method in a Smalltalk
browser, the code panel only shows the source of that particular method.


—
Hwee-Boon
http://hboon.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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

#136784 From: Thiago Padilha <tpadilha84@...>
Date: Mon Mar 18, 2013 11:12 am
Subject: Re: Save all buffers on SIGTERM
tpadilha84@...
Send Email Send Email
 
thanks for the tip, Tony.

On Sun, Mar 17, 2013 at 4:09 AM, Tony Mechelynck
<antoine.mechelynck@...> wrote:
> On 16/03/13 18:44, Thiago Padilha wrote:
>>
>> Is it possible to configure vim to write all buffers when it receives
>> SIGTERM? I use vim inside multiple  tmux sessions and sometimes I
>> forget to save something so when I shutdown the computer and reboot
>> there's a bunch of .swp files around(I would rather have vim save
>> everything)
>>
>> I already tried the autowriteall option but it only works when exiting
>> vim cleanly
>>
>
> Maybe this? (untested)
>
>         " save everything if terminated by an interceptible signal
>         :aucmd VimLeave * if v:dying | wall | endif
>
> or this?
>
>         " delete swapfile if the swapped file is 'nomodified'
>         :au SwapExists * if !&mod | let v:swapchoice = 'd' | endif
>
>
> Best regards,
> Tony.
> --
> BEDEVERE: Stand by for attack!!
>    [CUT TO enormous army forming up.  Trebuchets, rows of PIKEMEN, siege
>    towers, pennants flying, shouts of "Stand by for attack!"  Traditional
>    army build-up shots.  The shouts echo across the ranks of the army.
>    We see various groups reacting, and stirring themselves in readiness.]
> ARTHUR:   Who are they?
> BEDEVERE: Oh, just some friends!
>                  "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES
> LTD
>
> --
> --
> 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/groups/opt_out.
>
>

--
--
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/groups/opt_out.

#136785 From: Ethan Hereth <advocateddrummer@...>
Date: Mon Mar 18, 2013 12:13 pm
Subject: Re: "Focus mode" plugin that only shows one function in a buffer?
advocateddrummer@...
Send Email Send Email
 
I think Christian Brabandt's Narrow Region might be what you are looking for?

https://github.com/chrisbra/NrrwRgn


On Mon, Mar 18, 2013 at 6:04 AM, Hwee-Boon Yar <hweeboon@...> wrote:
Is there a plugin or way for me to just display and edit a single function in a buffer? I'm been using MacVim for a few years now and have been mostly working with ObjC, Python and Ruby which all has the concept of a function. Lately I've been yearning for a way (from my Smalltalk roots[1]) to just view and edit just a single function in a buffer, a sort of reverse-folding.

Is there a way to achieve this? Thanks

[1] For those familiar with Smalltalk, when you click on a method in a Smalltalk browser, the code panel only shows the source of that particular method.



Hwee-Boon
http://hboon.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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.



--
--
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/groups/opt_out.
 
 

#136786 From: Marc Weber <marco-oweber@...>
Date: Mon Mar 18, 2013 12:52 pm
Subject: Re: Why is Vimscript/VimL much slower than Python when traversing long lists?
marco-oweber@...
Send Email Send Email
 
Excerpts from Vlad Irnov's message of Mon Mar 18 11:16:51 +0100 2013:
> On 3/15/13, Marc Weber <marco-oweber@...> wrote:
> > VimL is known to be slow.
> Saying that VimL is slow is pointless without explaining exactly what is
> slow(er) and by how much.

I've tried hacking a delphi completion once. Even though using
aggressive caching in VimL completion was slower than 1sec.

The other thing I tried is parsing viml files, to implement a tag like
goto function feature and more - it also takes more than 15 sec to parse
and cache all .vim files the first time .

Such implementations horribly fail on large source bases such as flex
sdk (actionscript).

Sorry - I don't know what exactly is slow - and I don't care.

My impression of UltiSnips vs snipmate (viml) is the same: that the
python implementation is faster.

No, its not an accurate benchmark. And to be honest I don't care.
Same about YouCompleteMe vs NeoComplCache (YouCompleteMe is written in C
for a strong reason: speed).

Applying regex to many lines is likely to be one point - but there might
be more.

Whenever you have huge amounts of data don't use viml unless you can use
viml builtins (this also applies to :g :v vs :!%grep etc)

You're right that it could be possible to optimize VimL and identify the
problems (split or join was one which got fixed). But I don't have time
to do so - if other solutions already work.

Marc Weber

--
--
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/groups/opt_out.

#136787 From: Marcos Souza <marcos.souza.org@...>
Date: Mon Mar 18, 2013 1:54 pm
Subject: Add extensions to sintax highlight - .qml
marcos.souza.org@...
Send Email Send Email
 
Hi guys!

I use vim for write C/C++, python, html and others file formats.

But, a few days ago I started to work with Qt Framework, and use QML file
format.

This file extension is very similiar to Javascript (we can write js scripts
inside it), and I want to know if there is a way to add this file to default
syntax highlight of vim.

If this is possible I can send patches to achieve this, but I will need some
code pointers :)

Thanks since now guys!

--
--
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/groups/opt_out.

#136788 From: Philip Rhoades <phil@...>
Date: Mon Mar 18, 2013 5:49 pm
Subject: Re: Aligning slowing down (:1,$Align |)
phil@...
Send Email Send Email
 
On Thursday, 14 March 2013 14:33:12 UTC+11, toothpik  wrote:
> On Thu, Mar 14, 2013 at 01:48:05PM +1100, Philip Rhoades wrote:
>
> > People,
>
>
>
> > I have been using this plugin for some time now and it has been
>
> > exactly what I wanted.  One thing I use it for is to align text that
>
> > has been pasted into a file from online bank payments (I have been
>
> > burnt in the past by relying on the banks records and not having my
>
> > own) but I have noticed that as my receipts text file gets larger,
>
> > the align command starts slowing down dramatically and I think it
>
> > might be hanging now - I have to kill the process, reopen the file,
>
> > recover the file in Vim - and mostly it has seemed OK.  The text
>
> > file is now 2103 lines - I am expecting too much of this plugin?
>
>
>
> why align the whole file every time?  why not align only the freshly
>
> pasted receipts?



Because the comments in the first column vary in length and the longest one
might be halfway through the file - but see the next response for a fix that
should work for a while.

Thanks,

Phil.

--
--
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/groups/opt_out.

#136789 From: Philip Rhoades <phil@...>
Date: Mon Mar 18, 2013 5:53 pm
Subject: Re: Aligning slowing down (:1,$Align |)
phil@...
Send Email Send Email
 
DrChip,


On Friday, 15 March 2013 01:59:25 UTC+11, DrChip  wrote:
> tooth pik wrote:
>
> > On Thu, Mar 14, 2013 at 01:48:05PM +1100, Philip Rhoades wrote:
>
> >> People,
>
> >> I have been using this plugin for some time now and it has been
>
> >> exactly what I wanted.  One thing I use it for is to align text that
>
> >> has been pasted into a file from online bank payments (I have been
>
> >> burnt in the past by relying on the banks records and not having my
>
> >> own) but I have noticed that as my receipts text file gets larger,
>
> >> the align command starts slowing down dramatically and I think it
>
> >> might be hanging now - I have to kill the process, reopen the file,
>
> >> recover the file in Vim - and mostly it has seemed OK.  The text
>
> >> file is now 2103 lines - I am expecting too much of this plugin?
>
> > why align the whole file every time?  why not align only the freshly
>
> > pasted receipts?
>
> >
>
> * See if  using   let g:Align_xstrlen= 0   speeds things up a bit (:help
>
> align-option).  Don't use this setting if you're using multibyte
>
> characters, though -- it won't align properly then.
>
> * Set up a dummy line and align using it and new stuff.  As an example,
>
> let's assume that you're using |s as field delimiters:
>
>
>
>     |one|two|three|four
>
>     |four|three|two|one
>
>
>
>   After aligning these, one gets (use a monospace font to see this properly)
>
>
>
>     |one |two  |three|four
>
>     |four|three|two  |one
>
>
>
> Then take the last line and convert it into a "dummy" line:
>
>
>
>    Yp:s/[^|]/\~/g
>
> yielding
>
>     |~~~~|~~~~~|~~~~~|~~~
>
>
>
> Aligning your new entries with the dummy line should speed things up a
>
> lot.  You could wrap that process into a custom mapping, too (and have
>
> it generate the dummy line, align, remove the dummy line).



Yes!  A dummy line is the answer - if I create that line at the top of the file
(I add new receipts at the top) then I would only need to do the whole file
again if my comment line happens to be longer than the previous longest comment
in the file  (I probably should have thought of that I guess).

Thanks!

Phil.

--
--
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/groups/opt_out.

#136790 From: MickMcQ <mcq@...>
Date: Mon Mar 18, 2013 6:29 pm
Subject: Re: Vim on the iPad
mcq@...
Send Email Send Email
 
I'd like to add that I use Vim in two main ways on the iPad 3. Most often, I log
into a remote Mac using either iSSH or iTeleport. No iPad text editor conserves
keystrokes the way Vim does, so that's my main motivation.

iSSH has the option of a translucent keyboard so that I can see a much larger
terminal if I don't use a Bluetooth keyboard---and I don't usually use a
Bluetooth keyboard, even though I have two. The iPad is just too convenient to
pull out in situations where a keyboard is impractical.

Another advantage of iSSH is that, if someone else in my household is using the
Mac, my session does not interfere with their use. The Mac must be set to allow
remote login from System Preferences > Sharing > Remote Login. When I check the
Remote Login box, a message appears telling you to type

ssh myusername@...

to login. In iSSH, I enter this info into some dialog boxes, leaving the default
port box empty. I have also done using Amazon's servers or my University's
servers when in public.  In these cases I usually use gnu screen at the remote
end so that, if I am disconnected, my running copy of Vim on the remote machine
is not affected. I believe many people use tmux for the same purpose.

iTeleport gets much more use from me than iSSH. It requires me to check the box
marked "Screen Sharing" on the Mac and to run iTeleport Connect on the Mac. It
has the disadvantage that my session requires a physical screen on the Mac (you
can buy a dongle that makes a Mac think it has a screen plugged in to overcome
that). On my home Mac there are two screens, one of which is often in use as a
TV, so I usually use the other one.

The iPad really shines with iTeleport because I can resize and reshape the
window so effortlessly.  Also, if I have a network problem my copy of Vim
continues to run on the remote Mac without loss.

At my office, I leave my Mac on my desktop and take the iPad to meetings,
logging in to the Mac using iTeleport. There is a potential security risk here
in that I can't lock the screen on my desktop Mac while I'm using it from a
remote location. I can turn the display off so that it is not obvious that it is
available but that constitutes "security by obscurity" and is never recommended
as a replacement for security. iSSH, of course, overcomes the security objection
because it does not use the display on the Mac.

I also have Vim on the iPad from the app store. It is actually being developed
as far as I can tell. You simply have to download it from github and compile it
yourself to get new features, such as the iPhone 5 screen adjustment. I believe
that a number of people have modified the code for their own use and described
their patches on mailing lists.  It's not as convenient as it would be to update
the app store version, of course.

I used to carry a Bluetooth keyboard but found that I rarely used it except when
sitting at tables in the library for long periods. If I expect to use the iPad
for less than half an hour, I can't justify even the extra few seconds to dig
out the Bluetooth keyboard.

I have used Vim on various Android tablets and found it wanting for the most
part. I have yet to find a single Android device I like as a daily driver,
despite the unique advantages of some Android devices.

On the other hand, the Nexus 10 with Ubuntu Unity may make a better daily Vim
platform than the iPad. I would not give up the iPad 3 for it but it would be
far easier for me to carry the Nexus 10 and the iPad 3 than the iPad 3 and a
laptop.  I'm impressed by the video at http://youtu.be/fNYgevHf9EI where the
Canonical representative shows the use of a search function to find features in
a photo app. He begins to type the word crop when he wants to crop a picture and
the crop menu appears.  I would like to find features this way because I
remember features more easily by words than by menu location.  As a contrast,
the video at http://youtu.be/GKBy6PgOors shows an antagonistic attitude toward
this initiative but the reviewers appear to thrive more on snark than insight.

Finally, I would like to add that there are two main reasons why I would not
give up the iPad. The first is Apple hardware quality.  I'm not talking about
specifications here, just quality.  Apple is very hard to beat and will remain
so for some time.  Finally, since the original poster mentioned pdfs, I should
add that my favorite use of the iPad is to read pdfs with Goodreader. I have not
found a better pdf reader on any platform, including Android, X11, and Mac. I'm
also really intrigued by iNib, a rough but brilliant handwriting app on the iPad
with no rival on any platform. I have to guess that I use about a dozen apps on
the iPad, and I would not want to give them up, but I do occasionally buy
Android devices and hope to find a keeper there eventually.


--
--
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/groups/opt_out.

#136791 From: FlashBurn <rail.shafigulin@...>
Date: Mon Mar 18, 2013 10:39 pm
Subject: redir and glob
rail.shafigulin@...
Send Email Send Email
 
I want to create a list of files that my project is using. This list will be
stored in a file and subsequently will be used by cscope.

Here is what I have so far:

function! BuildFileList()
   s:dir_list = ['dir1', 'dir2', 'dir3']
   s:output_file = 'cscope.files'
   redir! > s:output_file
   for dir in s:dir_list
     glob(dir.'*.[ch]')
   endfor
redir END
endfunction

silent call BuildFileList

I'm getting the following errors when I execute this function:
E190: Cannot open "s:output_file" for writing
E486: Pattern not found: dir."*.[ch]"

Obviously there is something wrong with the way I use redir and glob, but I
can't get my finger on it. Does anybody know what am I doing wrong?

Any help is really appreciated.

--
--
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/groups/opt_out.

#136792 From: Salman Halim <salmanhalim@...>
Date: Mon Mar 18, 2013 11:16 pm
Subject: Re: redir and glob
salmanhalim@...
Send Email Send Email
 


On Monday, March 18, 2013, FlashBurn wrote:
I want to create a list of files that my project is using. This list will be stored in a file and subsequently will be used by cscope.

Here is what I have so far:

function! BuildFileList()
  s:dir_list = ['dir1', 'dir2', 'dir3']
  s:output_file = 'cscope.files'
  redir! > s:output_file
  for dir in s:dir_list
    glob(dir.'*.[ch]')
  endfor
redir END
endfunction

silent call BuildFileList

I'm getting the following errors when I execute this function:
E190: Cannot open "s:output_file" for writing
E486: Pattern not found: dir."*.[ch]"

Obviously there is something wrong with the way I use redir and glob, but I can't get my finger on it. Does anybody know what am I doing wrong?

Any help is really appreciated.

--
--
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/groups/opt_out.


Redir requires an actual file name, not a variable name. Use :execute. 

execute "redir! > " . s:variable

Also, unless the "dir" ends in a slash, you will end up with the pattern right next to the directory name without the separator. Stick a slash in there to see if it helps. 

dir . "/*.[ch]"

You didn't ask this, but unless your files end in [ch] (and not just ch), you may be out of luck. 

Salman 


--
سلمان حلیم

--
--
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/groups/opt_out.
 
 

Messages 136763 - 136792 of 137773   Oldest  |  < Older  |  Newer >  |  Newest
Add to My Yahoo!      XML What's This?

Copyright © 2010 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines NEW - Help