From 5ca08433216edae5e160a3764d2200d565fcd565 Mon Sep 17 00:00:00 2001 From: Curtis McEnroe Date: Mon, 10 Sep 2018 14:49:00 -0400 Subject: Add mdoc syntax file --- home/.config/nvim/ftdetect/mdoc.vim | 1 + home/.config/nvim/syntax/mdoc.vim | 12 ++++++++++++ 2 files changed, 13 insertions(+) create mode 100644 home/.config/nvim/ftdetect/mdoc.vim create mode 100644 home/.config/nvim/syntax/mdoc.vim (limited to 'home/.config/nvim') diff --git a/home/.config/nvim/ftdetect/mdoc.vim b/home/.config/nvim/ftdetect/mdoc.vim new file mode 100644 index 00000000..b845fee6 --- /dev/null +++ b/home/.config/nvim/ftdetect/mdoc.vim @@ -0,0 +1 @@ +autocmd BufRead,BufNewFile *.[1-9] set filetype=mdoc diff --git a/home/.config/nvim/syntax/mdoc.vim b/home/.config/nvim/syntax/mdoc.vim new file mode 100644 index 00000000..d9d587f5 --- /dev/null +++ b/home/.config/nvim/syntax/mdoc.vim @@ -0,0 +1,12 @@ +if exists("b:current_syntax") + finish +endif + +runtime! syntax/nroff.vim +unlet! b:current_syntax + +setlocal sections+=ShSs +syntax match mdocBlank /^\.$/ conceal +setlocal conceallevel=2 + +let b:current_syntax = "mdoc" -- cgit 1.4.1