Skip to content

Commit

Permalink
Revert "refactor: Execute autocmd in group scope"
Browse files Browse the repository at this point in the history
This reverts commit 18ed14a.

Do not need "augroup" for "ftdetect", see :h ftdetect, and
"filetypedetect" may is a autocmd group name.
  • Loading branch information
StarryLeo committed Feb 22, 2022
1 parent b4dc23e commit f868afa
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions ftdetect/markdown.vim
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
augroup VimMarkdown
autocmd!
augroup END

if !has('patch-7.4.480')
" Before this patch, vim used modula2 for .md.
au! VimMarkdown filetypedetect BufRead,BufNewFile *.md
au! filetypedetect BufRead,BufNewFile *.md
endif

" markdown filetype file
au VimMarkdown BufRead,BufNewFile *.{md,mdx,mdown,mkd,mkdn,markdown,mdwn} setfiletype markdown
au VimMarkdown BufRead,BufNewFile *.{md,mdx,mdown,mkd,mkdn,markdown,mdwn}.{des3,des,bf,bfa,aes,idea,cast,rc2,rc4,rc5,desx} setfiletype markdown
au BufRead,BufNewFile *.{md,mdx,mdown,mkd,mkdn,markdown,mdwn} setfiletype markdown
au BufRead,BufNewFile *.{md,mdx,mdown,mkd,mkdn,markdown,mdwn}.{des3,des,bf,bfa,aes,idea,cast,rc2,rc4,rc5,desx} setfiletype markdown

0 comments on commit f868afa

Please sign in to comment.