use autocmd! [group] to remove the auto-commands

This commit is contained in:
itchyny
2020-11-10 22:34:57 +09:00
parent 53176a0b75
commit 2d482e82f2

View File

@@ -2,7 +2,7 @@
" Filename: autoload/lightline.vim " Filename: autoload/lightline.vim
" Author: itchyny " Author: itchyny
" License: MIT License " License: MIT License
" Last Change: 2020/11/05 20:04:51. " Last Change: 2020/11/10 22:25:26.
" ============================================================================= " =============================================================================
let s:save_cpo = &cpo let s:save_cpo = &cpo
@@ -55,9 +55,7 @@ function! lightline#enable() abort
autocmd ColorScheme * if !has('vim_starting') || expand('<amatch>') !=# 'macvim' autocmd ColorScheme * if !has('vim_starting') || expand('<amatch>') !=# 'macvim'
\ | call lightline#update() | call lightline#highlight() | endif \ | call lightline#update() | call lightline#highlight() | endif
augroup END augroup END
augroup lightline-disable autocmd! lightline-disable
autocmd!
augroup END
augroup! lightline-disable augroup! lightline-disable
endfunction endfunction
@@ -68,9 +66,7 @@ function! lightline#disable() abort
call settabwinvar(t, n, '&statusline', '') call settabwinvar(t, n, '&statusline', '')
endfor endfor
endfor endfor
augroup lightline autocmd! lightline
autocmd!
augroup END
augroup! lightline augroup! lightline
augroup lightline-disable augroup lightline-disable
autocmd! autocmd!