Merge pull request #163 from buztard/fixes/hunks

hunks: Display the hunks summary only if Git Gutter is enabled
This commit is contained in:
Bailey Ling 2013-08-20 08:10:04 -07:00
commit 35db000651
1 changed files with 3 additions and 0 deletions

View File

@ -5,6 +5,9 @@ let s:non_zero_only = get(g:, 'airline#extensions#hunks#non_zero_only', 0)
let s:hunk_symbols = get(g:, 'airline#extensions#hunks#hunk_symbols', ['+', '~', '-']) let s:hunk_symbols = get(g:, 'airline#extensions#hunks#hunk_symbols', ['+', '~', '-'])
function! airline#extensions#hunks#get_hunks() function! airline#extensions#hunks#get_hunks()
if get(g:, 'gitgutter_enabled', 0) == 0
return ''
endif
let hunks = GitGutterGetHunkSummary() let hunks = GitGutterGetHunkSummary()
let string = '' let string = ''
for i in [0, 1, 2] for i in [0, 1, 2]