In my .vimrc I have the following line:
set textwidth=80
However, when editing the files: README-SETUP and README-INSTALL I would like vim to have textwidth set to 60.
I think this can be done for specific file types using autocmd, but how would I do it for specific files?
You could do this like so:
Or you could list the files one by one:
EDIT: As ZyX points out, prefer setlocal over set for options like this you really don’t want all buffers having that textwidth for the duration of the session.