After I applied vim-plug within "call plug#begin('~/.vim/bundle')" and "call plug#end()", I found my vim become auto-indent again even if I manually ":set nosmartindent" and ":set noautoindent".
If I remove "call plug#begin('~/.vim/bundle')" and "call plug#end()", no indention again.
So, I guess if this caused by vim-plug? And Is there any special command to disable the indention of this kind of ?
Thanks.
See https://github.com/junegunn/vim-plug#usage
plug#end()... automatically executes filetype plugin indent on and syntax enable. You can revert the settings after the call. e.g. filetype indent off, syntax off, etc.
Thanks. After add filetype indent off following call plug#end() in .vimrc, and reopen the source code, auto-indent disappear.
(Previously, I tried to manually input :filetype indent off in an opened vim, although from the result of checking :filetype, it turns off, but doesn't really take effect.)
Similarly, add filetype plugin off in .vimrc, some auto-complement feature (such inputing new line for /***/ style comment) is disabled.
@junegunn May I ask why this change to default behaviour is part of Vim Plug ?
This issue had me thinking I was losing my mind for a week or two before I found a Reddit post about this which led me to this issue.
Thank you for the great work on Vim Plug ! This is the only minor "complaint" I can find about this software. Easily fixed so no major issues for me.
Most helpful comment
Thanks. After add
filetype indent offfollowingcall plug#end()in .vimrc, and reopen the source code, auto-indent disappear.(Previously, I tried to manually input
:filetype indent offin an opened vim, although from the result of checking:filetype, it turns off, but doesn't really take effect.)Similarly, add
filetype plugin offin .vimrc, some auto-complement feature (such inputing new line for/***/style comment) is disabled.