News for hackers. Stuff that matters.
Re:Vim 9.0 by alisonatwork on Thursday June 30, 2022 @08:58PM (#31940783)
You can change it per filetype. For example, I have a similarly minimal vimrc that defaults to sw=4, ts=4 and expandtab, but with the following additions:

  autocmd FileType go,make,sh set noexpandtab
  autocmd FileType js,json set sw=2 ts=2
Edit: I think you might also need the following to make it trigger the FileType event when you open a file in the first place:

  filetype plugin indent on

There are no comments on this comment yet.