Adjusting TAB setting in vim

Robert Ambrose plug-discuss@lists.plug.phoenix.az.us
Tue, 22 Apr 2003 10:00:14 -0700 (MST)


You will want to do both shiftwidth(sw) and tabstop(ts).  I also like 
autoindent(ai).

A nice feature of vim is you can embed commands in a comment in the source
of whatever you are editing.

For C: /* vim ai sw=4 ts=4 */
For Perl, et.al.: # vim ai sw=4 ts=4
HTML:
<!--
vim: ai sw=4 ts=4
-->
(Notice it is not on one line, vim will not pick it up if it is.)

rna

On 22 Apr 2003, Bart Garst wrote:

> Does anyone know if it's possible to adjust the number of spaces the TAB
> key indents in vim? Right now it does 8 but I'd like it at 4.
> 
> vim 6.1
> RH 8.0
> 
> Thx,
> Bart
> 
> ---------------------------------------------------
> PLUG-discuss mailing list - PLUG-discuss@lists.plug.phoenix.az.us
> To subscribe, unsubscribe, or to change  you mail settings:
> http://lists.PLUG.phoenix.az.us/mailman/listinfo/plug-discuss
>