From ac1cb44d58747ac70a4077da3796a9f696ee46a9 Mon Sep 17 00:00:00 2001 From: Tim Pope Date: Sun, 8 Jul 2018 17:08:50 -0400 Subject: [PATCH] Set 'define' to match HTML ids in Haml files --- ftplugin/haml.vim | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ftplugin/haml.vim b/ftplugin/haml.vim index e74530b..bdc91d3 100644 --- a/ftplugin/haml.vim +++ b/ftplugin/haml.vim @@ -37,6 +37,8 @@ endif runtime! ftplugin/ruby.vim ftplugin/ruby_*.vim ftplugin/ruby/*.vim let b:did_ftplugin = 1 +let &l:define .= empty(&l:define ? '' : '\|') . '^\s*\%(%\w*\)\=\%(\.[[:alnum:]_-]\+\)*#' + " Combine the new set of values with those previously included. if exists("b:undo_ftplugin") let s:undo_ftplugin = b:undo_ftplugin . " | " . s:undo_ftplugin @@ -60,7 +62,7 @@ endif setlocal comments= commentstring=-#\ %s -let b:undo_ftplugin = "setl cms< com< " +let b:undo_ftplugin = "setl def< cms< com< " \ " | unlet! b:browsefilter b:match_words | " . s:undo_ftplugin let &cpo = s:save_cpo