[lug] Vi and Bracket Indenting
Bill Thoen
bthoen at gisnet.com
Tue Oct 11 17:48:09 MDT 2005
I'm trying to figure how to change vi's indenting behavior after typing a
curly bracket when writing C code. It seems to indent code between { }
brackets far too deeply. For example:
int test()
{
/* codes starts way out here */
}
but what I want is an indent of one tab, set to about 2 or 4 spaces.
I tried a vin rc file and when I used it with vi -u vimrc I got no default
indent behavior, so I thought, "ah ha! the key is in here!" So I
progressively commented out each setting, and guess what? It was none of
these. The default indent behavior is somewhere else. But where? And how do
I modify it?
Anyone know?
TIA,
- Bill Thoen
More information about the LUG
mailing list