vim editor question--avoid tabs in autoindent

Anyone know how to have vim *not* use tabs, but use spaces instead when autoindent is turned on?

For example, when autoindent is on, vim uses tab characters to get close to the correction indentation location on the new line. I don't want any tabs at the beginning of each line--can vim do this automatically (I know lemmy can).

I know that I can do a global substitution, but that's a pain (since I might forget).
LVL 3
tgoetzeAsked:
Who is Participating?
 
MoondancerConnect With a Mentor Commented:
I have refunded your points here, tgoetze.  I will move to the PAQ rather than deleting it so that sdussinger has an opportunity see get the Email notification of the duplicate question to post there as well.

Thank you,
Moondancer
Community Support Moderator @ Experts Exchange
0
 
sdussingerCommented:
I think if you use the expandtabs setting, VIM will convert tabs to spaces.  Try :set et in your vimrc file...

--Steve
0
 
tgoetzeAuthor Commented:
Duplicate question, and another person has already responded. See question 20154599.

Sorry.
0
All Courses

From novice to tech pro — start learning today.