From c16bdeb22274bb381b1b27ce27458d18b016fac8 Mon Sep 17 00:00:00 2001 From: June 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 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