pandoc 转换html,使用pandoc实现markdown和latex以及html的互转

安装

Archlinux下安装很简单

# pacman -S pandoc

使用

$ pandoc -h

pandoc [OPTIONS] [FILES]

Input formats: native, markdown, markdown+lhs, rst, rst+lhs, html, latex, latex+lhs

Output formats: native, html, html+lhs, s5, docbook, opendocument, odt, latex, latex+lhs, context, texinfo, man, markdown, markdown+lhs, plain, rst, rst+lhs, mediawiki, rtf

Options:

-f FORMAT, -r FORMAT --from=FORMAT, --read=FORMAT

-t FORMAT, -w FORMAT --to=FORMAT, --write=FORMAT

-s --standalone

-o FILENAME --output=FILENAME

-p --preserve-tabs

--tab-stop=TABSTOP

--strict

--reference-links

-R --parse-raw

-S --smart

-m[URL] --latexmathml[=URL], --asciimathml[=URL]

--mathml[=URL]

--mimetex[=URL]

--jsmath[=URL]

--gladtex

-i --incremental

--xetex

-N --number-sections

--no-wrap

--sanitize-html

--email-obfuscation=none|javascript|references

--id-prefix=STRING

--indented-code-classes=STRING

--toc, --table-of-contents

--base-header-level=LEVEL

--template=FILENAME

-V FILENAME --variable=FILENAME

-c URL --css=URL

-H FILENAME --include-in-header=FILENAME

-B FILENAME --include-before-body=FILENAME

-A FILENAME --include-after-body=FILENAME

-C FILENAME --custom-header=FILENAME

-T STRING --title-prefix=STRING

--reference-odt=FILENAME

-D FORMAT --print-default-template=FORMAT

--data-dir=DIRECTORY

--dump-args

--ignore-args

-v --version

-h --help

示例

$ pandoc -f markdown -t html -o demo.html demo.md

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值