An anonymous reader writes:
You can open a file on the command line and automatically put the cursor on the last line by typing:
vim + file
If you want vim to start at a specific line you can do the following instead:
vim +LINENUMBER file
Thanks for the tip!
Tuesday, December 1, 2009
Subscribe to:
Post Comments (Atom)
3 comments:
similarly you can jump to a search pattern by the following way:
vim +/PATTERN file
Similarly, when the Vim process is already launched, there are many ways to jump to a particular line:
42gg
to jump to line 42. Alternatively using ex mode:
:42
Relative jumps:
42%
where 0% is the beginning of the file and 100% the end.
I like your writing style. Nice blog.
Post a Comment