Misuse of <tab>

James Graves ansible at typhoon.xnet.com
Thu Jul 31 21:29:34 CEST 2003


Asun Friere <afriere at yahoo.co.uk> wrote:

>If you use vim remember to put 'set expandtab' (or if you wanna be
>fancy 'au BufRead,BufNewFile *.py set expandtab' ) into your .vimrc
>(or .exrc) file.  This way you can use '[Ctrl]-[T]' and '[Ctrl]-[D]'
>to in- and un-dent in insert mode, as well as '>>' and '<<' in command
>mode, without fear of hard tabs being inserted.  (Though the way vi(m)
>mixes tabs and spaces is consistent enough that you wouldn't usually
>get into any trouble with it.)

That's handy.  I had known about 'set expandtab' for a while, but I
wanted to figure out how to use it for just Python.

And now I don't have to.

Thanks,

James Graves




More information about the Python-list mailing list