Last active
December 31, 2015 16:49
-
-
Save christian-marie/8016208 to your computer and use it in GitHub Desktop.
.vim/plugin/c.vim
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fu Select_c_style() | |
set tabstop=8 "A tab is 8 spaces | |
set expandtab "Always uses spaces instead of tabs | |
set softtabstop=8 "Insert 4 spaces when tab is pressed | |
set shiftwidth=8 "An indent is 4 spaces | |
set smarttab "Indent instead of tab at start of line | |
set shiftround "Round spaces to nearest shiftwidth multiple | |
set foldmethod=syntax | |
" set nojoinspaces "Don't convert spaces to tabs | |
endf | |
au BufRead,BufNewFile *.c call Select_c_style() | |
au BufRead,BufNewFile *.h call Select_c_style() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment