mirror of
https://github.com/jdhao/nvim-config.git
synced 2025-06-08 14:14:33 +02:00
use 2 spaces for tabs by default
This removes a lot of code duplication. If we want to use 4 spaces, we can set it separately in their ftplugin settings.
This commit is contained in:
parent
d8b92965e8
commit
3539207913
@ -1,10 +1,5 @@
|
||||
set commentstring=//\ %s
|
||||
|
||||
set tabstop=2 " number of visual spaces per TAB
|
||||
set softtabstop=2 " number of spaces in tab when editing
|
||||
set shiftwidth=2 " number of spaces to use for autoindent
|
||||
set expandtab " expand tab to spaces so that tabs are spaces
|
||||
|
||||
" Disable inserting comment leader after hitting o or O or <Enter>
|
||||
set formatoptions-=o
|
||||
set formatoptions-=r
|
||||
|
||||
@ -1,8 +1,3 @@
|
||||
" Disable inserting comment leader after hitting o or O or <Enter>
|
||||
set formatoptions-=o
|
||||
set formatoptions-=r
|
||||
|
||||
set tabstop=2 " number of visual spaces per TAB
|
||||
set softtabstop=2 " number of spaces in tab when editing
|
||||
set shiftwidth=2 " number of spaces to use for autoindent
|
||||
set expandtab " expand tab to spaces so that tabs are spaces
|
||||
|
||||
@ -2,11 +2,6 @@
|
||||
set formatoptions-=o
|
||||
set formatoptions-=r
|
||||
|
||||
set tabstop=2 " number of visual spaces per TAB
|
||||
set softtabstop=2 " number of spaces in tab when editing
|
||||
set shiftwidth=2 " number of spaces to use for autoindent
|
||||
set expandtab " expand tab to spaces so that tabs are spaces
|
||||
|
||||
nnoremap <silent> <F9> :luafile %<CR>
|
||||
|
||||
" For delimitMate
|
||||
|
||||
@ -8,5 +8,10 @@ set sidescroll=5
|
||||
set sidescrolloff=2
|
||||
set colorcolumn=100
|
||||
|
||||
set tabstop=4 " number of visual spaces per TAB
|
||||
set softtabstop=4 " number of spaces in tab when editing
|
||||
set shiftwidth=4 " number of spaces to use for autoindent
|
||||
set expandtab " expand tab to spaces so that tabs are spaces
|
||||
|
||||
" For delimitMate
|
||||
let b:delimitMate_matchpairs = "(:),[:],{:}"
|
||||
|
||||
@ -1,6 +1 @@
|
||||
set commentstring=--\ %s
|
||||
|
||||
set tabstop=2 " number of visual spaces per TAB
|
||||
set softtabstop=2 " number of spaces in tab when editing
|
||||
set shiftwidth=2 " number of spaces to use for autoindent
|
||||
set expandtab " expand tab to spaces so that tabs are spaces
|
||||
|
||||
@ -1,4 +0,0 @@
|
||||
set tabstop=2 " number of visual spaces per TAB
|
||||
set softtabstop=2 " number of spaces in tab when editing
|
||||
set shiftwidth=2 " number of spaces to use for autoindent
|
||||
set expandtab " expand tab to spaces so that tabs are spaces
|
||||
@ -12,9 +12,4 @@ set foldmethod=expr foldexpr=utils#VimFolds(v:lnum) foldtext=utils#MyFoldText()
|
||||
" see `:h K` and https://stackoverflow.com/q/15867323/6064933
|
||||
set keywordprg=:help
|
||||
|
||||
set tabstop=2 " number of visual spaces per TAB
|
||||
set softtabstop=2 " number of spaces in tab when editing
|
||||
set shiftwidth=2 " number of spaces to use for autoindent
|
||||
set expandtab " expand tab to spaces so that tabs are spaces
|
||||
|
||||
nnoremap <silent> <F9> :source %<CR>
|
||||
|
||||
@ -1,8 +1,3 @@
|
||||
set tabstop=2 " number of visual spaces per TAB
|
||||
set softtabstop=2 " number of spaces in tab when editing
|
||||
set shiftwidth=2 " number of spaces to use for autoindent
|
||||
set expandtab " expand tab to spaces so that tabs are spaces
|
||||
|
||||
" Turn off syntax highlighting for large YAML files.
|
||||
if line('$') > 500
|
||||
setlocal syntax=OFF
|
||||
|
||||
@ -44,9 +44,9 @@ set backup " create backup for files
|
||||
set backupcopy=yes " copy the original file to backupdir and overwrite it
|
||||
|
||||
" General tab settings
|
||||
set tabstop=4 " number of visual spaces per TAB
|
||||
set softtabstop=4 " number of spaces in tab when editing
|
||||
set shiftwidth=4 " number of spaces to use for autoindent
|
||||
set tabstop=2 " number of visual spaces per TAB
|
||||
set softtabstop=2 " number of spaces in tab when editing
|
||||
set shiftwidth=2 " number of spaces to use for autoindent
|
||||
set expandtab " expand tab to spaces so that tabs are spaces
|
||||
|
||||
" Set matching pairs of characters and highlight matching brackets
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user