Skip to content

Commit 29ec69f

Browse files
committed
Set default tabstop to 2, but only if not changed
1 parent 6636144 commit 29ec69f

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

ftdetect/polyglot.vim

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2634,6 +2634,10 @@ if !has_key(s:disabled_packages, 'autoindent')
26342634
" Code below re-implements sleuth for vim-polyglot
26352635
let g:loaded_sleuth = 1
26362636

2637+
if &tabstop == 8
2638+
let &tabstop = 2
2639+
endif
2640+
26372641
func! s:get_shiftwidth(indents) abort
26382642
let shiftwidth = 0
26392643
let max_count = 0

0 commit comments

Comments
 (0)