Add yaml frontmatter support to markdown

This commit is contained in:
Kenneth Benzie 2017-01-05 23:17:04 +00:00
parent f851feb40d
commit c0a2bb9bb2
2 changed files with 7 additions and 1 deletions

View File

@ -48,3 +48,8 @@ syn match markdownTodo 'TODO'
hi link markdownTodo Todo hi link markdownTodo Todo
syn cluster markdownInline add=markdownTodo syn cluster markdownInline add=markdownTodo
" yaml frontmatter
syn region markdownFrontmatter matchgroup=markdownFrontmatterDelimiter start='\%^---' keepend end='^---' contains=@markdownHighlightyaml
hi default link markdownFrontmatterDelimiter Special

3
vimrc
View File

@ -131,7 +131,7 @@ let g:DoxygenToolkit_commentType = "C++"
" markdown live browser preview " markdown live browser preview
Plug 'suan/vim-instant-markdown' Plug 'suan/vim-instant-markdown'
let g:markdown_fenced_languages = ['cpp', 'c', 'cmake', 'sh', 'vim', 'python'] let g:markdown_fenced_languages = ['cpp', 'c', 'cmake', 'sh', 'vim', 'python', 'yaml']
" xterm-color-table.vim - view term and hex colors " xterm-color-table.vim - view term and hex colors
Plug 'guns/xterm-color-table.vim' Plug 'guns/xterm-color-table.vim'
@ -143,6 +143,7 @@ Plug 'tikhomirov/vim-glsl'
Plug 'beyondmarc/hlsl.vim' Plug 'beyondmarc/hlsl.vim'
Plug 'frasercrmck/opencl.vim' Plug 'frasercrmck/opencl.vim'
Plug 'asciidoc/vim-asciidoc' Plug 'asciidoc/vim-asciidoc'
Plug 'mustache/vim-mustache-handlebars'
if filereadable(expand('~/.vim/local.vim')) if filereadable(expand('~/.vim/local.vim'))
source ~/.vim/local.vim source ~/.vim/local.vim