Neovim - How can I set a permanent default indentation for python files to X spaces?
I have searched to find a solution in Neovim, but have observed that even if I set these variables in a configuration file, vim.opt.tabstop = 2 vim.opt.softtabstop = 2 vim.opt.shiftwidth = 2 unfortunately, for python files a separate additional line is needed: vim.cmd [[autocmd FileType python set shiftwidth=2 tabstop=2 expandtab]] If this line is not provided, e.g the tabstop option is not applied but only in python files This is also possibly related to this question: NeoVim tab size (shiftwidth, tabstop) constantly changing in Insert mode in Lua files In this answer, the usage of the g:pyth
0 upvotes
View original discussion ↗
Comments
Sign in or sign up to comment and upvote.
No comments yet.