diff options
Diffstat (limited to 'autoload/puppet')
-rw-r--r-- | autoload/puppet/align.vim | 4 | ||||
-rw-r--r-- | autoload/puppet/ctags.vim | 10 |
2 files changed, 7 insertions, 7 deletions
diff --git a/autoload/puppet/align.vim b/autoload/puppet/align.vim index 56270f09..811dee3d 100644 --- a/autoload/puppet/align.vim +++ b/autoload/puppet/align.vim @@ -2,11 +2,11 @@ if polyglot#init#is_disabled(expand('<sfile>:p'), 'puppet', 'autoload/puppet/ali finish endif -function! puppet#align#IndentLevel(lnum) +function! puppet#align#IndentLevel(lnum) abort return indent(a:lnum) / &shiftwidth endfunction -function! puppet#align#LinesInBlock(lnum) +function! puppet#align#LinesInBlock(lnum) abort let lines = [] let indent_level = puppet#align#IndentLevel(a:lnum) diff --git a/autoload/puppet/ctags.vim b/autoload/puppet/ctags.vim index e5c7321e..1a12890a 100644 --- a/autoload/puppet/ctags.vim +++ b/autoload/puppet/ctags.vim @@ -10,9 +10,9 @@ endif let s:ctags_options_dir = expand('<sfile>:p:h:h:h') . '/ctags/' " Return full path to option file for ctags application -function! puppet#ctags#OptionFile() +function! puppet#ctags#OptionFile() abort - if puppet#ctags#Type() == 'universal' + if puppet#ctags#Type() ==? 'universal' let l:ctags_options = 'puppet_u.ctags' else let l:ctags_options = 'puppet.ctags' @@ -22,13 +22,13 @@ endfunction " Return type of installed ctags application, " can be 'universal' or 'exuberant' -function! puppet#ctags#Type() +function! puppet#ctags#Type() abort if !s:ctags_type let l:version = system('ctags --version') - if l:version =~ 'Universal Ctags' + if l:version =~? 'Universal Ctags' let s:ctags_type = 'universal' - elseif l:version =~ 'Exuberant Ctags' + elseif l:version =~? 'Exuberant Ctags' let s:ctags_type = 'exuberant' else echoerr 'Unknown version of Ctags' |