Monday, February 24, 2014

Re: Get lines in non-current buffer

On Mon, Feb 24, 2014 at 06:02:23PM -0600, Ben Klein wrote:
> My question seems to be basically
> http://stackoverflow.com/questions/14544618/is-there-a-way-to-get-the-number-of-lines-of-a-buffer-in-vim-script:
> Is there an alternative to line() for getting line numbers from a
> buffer
> other than the current one? The only answer on that question involves
> Python.

it isn't python but

:let l = system("wc -l filename")

would be a way

--
_|_ _ __|_|_ ._ o|
|_(_)(_)|_| ||_)||<
|

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

No comments: