diff options
author | Bram Moolenaar <Bram@vim.org> | 2010-05-21 12:05:36 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2010-05-21 12:05:36 +0200 |
commit | 7a329911b9ae2b97453fd995bc3a6523cf3aab53 (patch) | |
tree | b75f6a117f48fe0c441b67cca09490f623233a74 /runtime/indent/haml.vim | |
parent | c6af8125c7593b3ca104bf1feac0d814fe76d92d (diff) | |
download | vim-git-7a329911b9ae2b97453fd995bc3a6523cf3aab53.tar.gz |
Updated runtime files.
Diffstat (limited to 'runtime/indent/haml.vim')
-rw-r--r-- | runtime/indent/haml.vim | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/runtime/indent/haml.vim b/runtime/indent/haml.vim index c1feee09a..079bd0513 100644 --- a/runtime/indent/haml.vim +++ b/runtime/indent/haml.vim @@ -1,7 +1,7 @@ " Vim indent file -" Language: HAML -" Maintainer: Tim Pope <vimNOSPAM@tpope.info> -" Last Change: 2007 Dec 16 +" Language: Haml +" Maintainer: Tim Pope <vimNOSPAM@tpope.org> +" Last Change: 2008 Sep 11 if exists("b:did_indent") finish @@ -44,8 +44,6 @@ function! GetHamlIndent() if indent == indent(lnum) let indent = cindent <= indent ? -1 : increase endif - "let indent = indent == indent(lnum) ? -1 : indent - "let indent = indent > indent(lnum) + &sw ? indent(lnum) + &sw : indent let group = synIDattr(synID(lnum,lastcol,1),'name') @@ -53,9 +51,11 @@ function! GetHamlIndent() return indent elseif line =~ '^/\%(\[[^]]*\]\)\=$' return increase - elseif line =~ '^:' + elseif group == 'hamlFilter' return increase - elseif line =~ '^'.s:tag.'[=~-]\s*\%(\%(if\|else\|elsif\|unless\|case\|when\|while\|until\|for\|begin\|module\|class\|def\)\>\%(.*\<end\>\)\@!\|.*do |[^|]*|\s*$\)' + elseif line =~ '^'.s:tag.'[&!]\=[=~-]\s*\%(\%(if\|else\|elsif\|unless\|case\|when\|while\|until\|for\|begin\|module\|class\|def\)\>\%(.*\<end\>\)\@!\|.*do\%(\s*|[^|]*|\)\=\s*$\)' + return increase + elseif line =~ '^'.s:tag.'[&!]\=[=~-].*,\s*$' return increase elseif line == '-#' return increase |