PSU uses emacs?

Ray Drew ray_drew at yahoo.co.uk
Wed Jan 24 05:56:42 EST 2001


On Fri, 19 Jan 2001 17:55:45 +0100, "Alex Martelli"
<aleaxit at yahoo.com> wrote:
[snip]
>> Any other tips for using gvim with Python?
>
>Use blank lines cleverly to delimit logical blocks, so { and } are
>useful movement-commands -- also increases readability.  Would be
>nice to have movement commands based on indent-levels, but, to be
>quite honest with you, I've never bothered programming them...
>(shame's about to engulf me...).  I like :set expandtab always
>on -- no tab/space confusion; I also like :set ff unix, so that my
>scripts can be shared between Win and Unix machines (and why
>waste one byte per line to tell a 'carriage' that is not there
>to 'return' [to where?]...?!-).
[snip]
>
>
>
>Alex
>

On Fri, 19 Jan 2001 17:55:45 +0100, "Alex Martelli"
<aleaxit at yahoo.com> wrote:
[snip]
>> Any other tips for using gvim with Python?
>
>Use blank lines cleverly to delimit logical blocks, so { and } are
>useful movement-commands -- also increases readability.  Would be
>nice to have movement commands based on indent-levels, but, to be
>quite honest with you, I've never bothered programming them...
>(shame's about to engulf me...).  I like :set expandtab always
>on -- no tab/space confusion; I also like :set ff unix, so that my
>scripts can be shared between Win and Unix machines (and why
>waste one byte per line to tell a 'carriage' that is not there
>to 'return' [to where?]...?!-).
[snip]
>
>
>
>Alex
>

I'm having problems getting the indentation right with gvim. I've got
the following in my .vmrc file:

au FileType py set ts=4
au FileType py set sw=4
au FileType py set expandtab on 
au FileType py set ff=unix

as far as I can make out from the docs, this should set those options
for all .py files. Tabs appear as 4 chars in gvim but when viewed in
an IDLE edtor window, tabs appear as 8 and throw a syntax error when
imported (files originally created in IDLE with tab space of 4). Do I
need to do anything else to get this to work?

Ray Drew
CIA UK





More information about the Python-list mailing list