diff options
author | Bram Moolenaar <Bram@vim.org> | 2016-08-30 23:26:57 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2016-08-30 23:26:57 +0200 |
commit | 89bcfda6834aba724d12554a34b9ed49f5789fd5 (patch) | |
tree | 2ffddcadaae9d061e38e17a09b2635ec199eb1dd /runtime/indent/gitconfig.vim | |
parent | 4792255eff03760dca0fd014616532e6d47db364 (diff) |
Updated runtime files. Remove version checks for Vim older than 6.0.
Diffstat (limited to 'runtime/indent/gitconfig.vim')
-rw-r--r-- | runtime/indent/gitconfig.vim | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/runtime/indent/gitconfig.vim b/runtime/indent/gitconfig.vim index 7d5d44b779..480c96d1b9 100644 --- a/runtime/indent/gitconfig.vim +++ b/runtime/indent/gitconfig.vim @@ -1,7 +1,7 @@ " Vim indent file " Language: git config file " Maintainer: Tim Pope <vimNOSPAM@tpope.org> -" Last Change: 2013 May 30 +" Last Change: 2016 Aug 29 if exists("b:did_indent") finish @@ -20,17 +20,18 @@ if exists("*GetGitconfigIndent") endif function! GetGitconfigIndent() + let sw = exists('*shiftwidth') ? shiftwidth() : &sw let line = getline(prevnonblank(v:lnum-1)) let cline = getline(v:lnum) if line =~ '\\\@<!\%(\\\\\)*\\$' " odd number of slashes, in a line continuation - return 2 * &sw + return 2 * sw elseif cline =~ '^\s*\[' return 0 elseif cline =~ '^\s*\a' - return &sw + return sw elseif cline == '' && line =~ '^\[' - return &sw + return sw else return -1 endif |