Added filetype autocommands for tab size
parent
50233e0b81
commit
896b2f58b6
10
vimrc
10
vimrc
|
@ -220,6 +220,16 @@ nnoremap <C-k> :set list! <CR>
|
||||||
command -nargs=1 F :r !figlet <q-args><CR>
|
command -nargs=1 F :r !figlet <q-args><CR>
|
||||||
command -nargs=1 Ff :r !figlet -f small <q-args><CR>
|
command -nargs=1 Ff :r !figlet -f small <q-args><CR>
|
||||||
|
|
||||||
|
nnoremap <C-p> :set tabstop=4 shiftwidth=4 noexpandtab<CR>
|
||||||
|
nnoremap <C-o> :set tabstop=8 shiftwidth=8 noexpandtab<CR>
|
||||||
|
|
||||||
|
|
||||||
|
" Autodetect filetypes and set proper indentation
|
||||||
|
" Default: 8
|
||||||
|
:set tabstop=8 shiftwidth=8 noexpandtab
|
||||||
|
:autocmd Filetype py setlocal tabstop=4 shiftwidth=4 noexpandtab
|
||||||
|
:autocmd Filetype lua setlocal tabstop=4 shiftwidth=4 noexpandtab
|
||||||
|
|
||||||
|
|
||||||
" ____ _ _
|
" ____ _ _
|
||||||
" | _ \| |_ _ __ _(_)_ __ ___
|
" | _ \| |_ _ __ _(_)_ __ ___
|
||||||
|
|
Loading…
Reference in New Issue