From 7709597a1d79e053587cb01f2a7d7c0f3e72d9ab Mon Sep 17 00:00:00 2001 From: Christian Clason Date: Fri, 29 Dec 2023 00:29:16 +0100 Subject: vim-patch:a907c9199216 runtime(sass): Provide sass_recommended_style option https://github.com/vim/vim/commit/a907c91992167e41da41008d4370e434e324cbf2 Co-authored-by: Tim Pope --- runtime/ftplugin/sass.vim | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'runtime/ftplugin') diff --git a/runtime/ftplugin/sass.vim b/runtime/ftplugin/sass.vim index 9ce446137a..e650be9312 100644 --- a/runtime/ftplugin/sass.vim +++ b/runtime/ftplugin/sass.vim @@ -1,7 +1,7 @@ " Vim filetype plugin " Language: Sass " Maintainer: Tim Pope -" Last Change: 2019 Dec 05 +" Last Change: 2023 Dec 28 " Only do this when not done yet for this buffer if exists("b:did_ftplugin") @@ -23,6 +23,11 @@ if &filetype =~# '\' 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(\)\=["'']\=' -- cgit