It's not necessary to summarize it, but as an amnesia. Like MacOSX
brew install pandoc
To install pandoc. Prepare the following script. Name it as make_markdown.py
and put it in an appropriate folder.
import sys
import glob
import commands
param = sys.argv
if (len(param) == 2):
f = param[1]
h = f[0:-3] + '.html'
command = "pandoc %s -s -o %s" % (f, h)
commands.getoutput(command)
quit()
Add the following to vimrc.
au FileType markdown setlocal makeprg=python\ ~/dotfiles/make_markdown.py\ %
Here, I installed it in ~ / dotfiles / make_markdown.py
.
This will issue a file like ʻa.html to ʻa.md
with the: make
command.
If you want to do something richer, you should probably install vim-pandoc.
Recommended Posts