From 3fdd0aa0243fcdde7b403122b3fd6d4bb43a3fdd Mon Sep 17 00:00:00 2001 From: Steve Dignam Date: Thu, 17 Mar 2016 23:36:32 -0400 Subject: [PATCH] added remark for markdown --- README.md | 3 +++ plugin/defaults.vim | 9 +++++++++ 2 files changed, 12 insertions(+) diff --git a/README.md b/README.md index 83bec77..55a51bf 100644 --- a/README.md +++ b/README.md @@ -176,6 +176,9 @@ Here is a list of formatprograms that are supported by default, and thus will be * `stylish-haskell` for __Haskell__ It can be installed using [`cabal`](https://www.haskell.org/cabal/) build tool. Installation instructions are available at https://github.com/jaspervdj/stylish-haskell#installation +* `remark` for __Markdown__. + A Javascript based markdown processor that can be installed with `npm install -g remark`. More info is available at https://github.com/wooorm/remark. + ## How can I change the behaviour of formatters, or add one myself? If you need a formatter that is not among the defaults, or if you are not satisfied with the default formatting behaviour that is provided by vim-autoformat, you can define it yourself. diff --git a/plugin/defaults.vim b/plugin/defaults.vim index 8a21b32..3a1349b 100644 --- a/plugin/defaults.vim +++ b/plugin/defaults.vim @@ -304,3 +304,12 @@ endif if !exists('g:formatters_haskell') let g:formatters_haskell = ['stylish_haskell'] endif + +" Markdown +if !exists('g:formatdef_remark_markdown') + let g:formatdef_remark_markdown = '"remark --silent --no-color"' +endif + +if !exists('g:formatters_markdown') + let g:formatters_markdown = ['remark_markdown'] +endif