aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authornsfisis <nsfisis@gmail.com>2023-08-30 15:56:26 +0900
committernsfisis <nsfisis@gmail.com>2023-09-01 09:25:28 +0900
commit490c6191717a930d6d7a38c97b1460730e8f1191 (patch)
treead01e12a8a92e60cf63958e6d7507cfa59500100
parentab4ff96af30910d6903149482722eed87f3b39a8 (diff)
downloaddotfiles-490c6191717a930d6d7a38c97b1460730e8f1191.tar.gz
dotfiles-490c6191717a930d6d7a38c97b1460730e8f1191.tar.zst
dotfiles-490c6191717a930d6d7a38c97b1460730e8f1191.zip
vim: enable editorconfig if bundled
-rw-r--r--.vimrc6
1 files changed, 6 insertions, 0 deletions
diff --git a/.vimrc b/.vimrc
index 371779e..8c6728e 100644
--- a/.vimrc
+++ b/.vimrc
@@ -153,6 +153,12 @@ autocmd Vimrc BufRead *
\ execute "normal g`\"" |
\ endif
+if has('patch-9.0.1799')
+ packadd editorconfig
+endif
+
+" TODO: Check if editorconfig is enabled before setting options in order to
+" avoid overriding options set by editorconfig.
autocmd Vimrc FileType c set expandtab tabstop=4 shiftwidth=4 softtabstop=4
autocmd Vimrc FileType cmake set expandtab tabstop=2 shiftwidth=2 softtabstop=2
autocmd Vimrc FileType cpp set expandtab tabstop=4 shiftwidth=4 softtabstop=4