[GRLUG] Vim Group? Editors and IDEs

John-Thomas Richards jtr at jrichards.org
Fri Jun 24 16:23:38 EDT 2011


On Fri, Jun 24, 2011 at 03:00:09PM -0400, Bob Kline wrote:
> vim UG?
> 
> I'm curious, how much of vim do most people actually use?

Enough to get the job done.  :-)

> I've been using vi for 30 years, and I doubt I use more than two dozen
> commands. I'm guessing that 99% of the work gets done with maybe 5% or
> less of the features of vi - now vim.

If `v' and 'V' are two separate commands, I guess I use about 50 or so
regularly.  That's plenty.  I frequently use more obscure (I think)
commands such as `gqap' (paragraph reformatter).

> * Open and close a file.  Maybe close it with :q! if the file has been
> mangled.  Maybe write the file out now and then with :w
> 
> *  yy or Nyy to yank a line or lines.
> 
> * p to put some lines in place.

Or `P' to paste above the current line.  ;-)

> * a, i, A, and I to add some stuff.
> 
> * ^ and $ to position at the beginning or end fo a line.
> 
> * cw or Ncw to change a word or words.
> 
> * dd, dw, D, x, X, to remove some stuff.
> 
> * :r file to, well, read in a file at a specific place.
> 
> * :1,$s/string1/string2/g to replace something everywhere in a file.
> 
> * / and ?  to find something, and n to find another occurrence.
> 
> Even that much seems to get one a long way.  On rare occasions I've
> used buffers, edited multiple files, etc.
> 
> What other things do people find handy?

See `gqap' above.  It's useful for reformatting an email that is ten
characters wide and 100 lines high.  ;-)  When I edit LaTeX in kile I
use line wrapping.  That really stinks in vim, though, so when I edit
the same file in vim I use this command to insert line breaks for ease
of editing (it makes no difference to LaTeX, however).  If I'm doing a
block of paragraphs the ol' `.' repeat command comes in quite handy.

                           I also like `ce'.
                          Guess what it does?
                           (This is a hint.)
-- 
john-thomas
------
I place economy among the first and most important republican virtues, and
public debt as the greatest of the dangers to be feared. To preserve our
independence, we must not let our rulers load us with perpetual debt.
Thomas Jefferson, third US president, architect and author (1743-1826)

-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.



More information about the grlug mailing list