mirror of
https://github.com/tpope/vim-haml.git
synced 2025-12-06 09:14:25 +08:00
Use recommended_style pattern for indenting defaults
This commit is contained in:
@@ -23,6 +23,11 @@ if &filetype =~# '\<s[ac]ss]\>'
|
||||
let b:undo_ftplugin .= ' isk<'
|
||||
endif
|
||||
|
||||
if get(g:, 'sass_recommended_style', 1)
|
||||
setlocal shiftwidth=2 softtabstop=2 expandtab
|
||||
let b:undo_ftplugin .= ' sw< sts< et<'
|
||||
endif
|
||||
|
||||
let &l:define = '^\C\v\s*%(\@function|\@mixin|\=)|^\s*%(\$[[:alnum:]-]+:|[%.][:alnum:]-]+\s*%(\{|$))@='
|
||||
let &l:include = '^\s*@import\s\+\%(url(\)\=["'']\='
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@ if exists("b:did_indent")
|
||||
endif
|
||||
let b:did_indent = 1
|
||||
|
||||
setlocal autoindent sw=2 et
|
||||
setlocal autoindent
|
||||
setlocal indentexpr=GetSassIndent()
|
||||
setlocal indentkeys=o,O,*<Return>,<:>,!^F
|
||||
|
||||
|
||||
Reference in New Issue
Block a user