LoginSignup
43
41

More than 5 years have passed since last update.

MacにPandocを入れてMarkdownをTextileに変換

Last updated at Posted at 2013-12-19

個人的にはMarkdownで何でも書きます。
だけど、仕事で使うRedmineTextile形式での入力が必要。
でも、Textileの記法は覚えられません。。(Backlogはwiki記法だし。。この時点で3記法。。。)

で、Pandocを使うことにしたので、それのインストール方法。

インストール

brew install pandoc

嘘。formulaがありません。なので、haskell-platform経由でインストールするらしい。

brew install haskell-platform
cabal update
cabal install pandoc

これ、だいぶ時間がかかります。自分は10分くらい。

終わったらPATHを通します。自分はzshなので、zshrcに

PATH=${HOME}/.cabal/bin:$PATH

と書いてやる。

確認

一旦、ターミナルを再起動し、

pandoc -v

pandoc 1.12.2.1
Compiled with texmath 0.6.5.2, highlighting-kate 0.5.5.1.
Syntax highlighting is supported for the following languages:
actionscript, ada, apache, asn1, asp, awk, bash, bibtex, boo, c, changelog,
clojure, cmake, coffee, coldfusion, commonlisp, cpp, cs, css, curry, d,
diff, djangotemplate, doxygen, doxygenlua, dtd, eiffel, email, erlang,
fortran, fsharp, gnuassembler, go, haskell, haxe, html, ini, java, javadoc,
javascript, json, jsp, julia, latex, lex, literatecurry, literatehaskell,
lua, makefile, mandoc, markdown, matlab, maxima, metafont, mips, modelines,
modula2, modula3, monobasic, nasm, noweb, objectivec, objectivecpp, ocaml,
octave, pascal, perl, php, pike, postscript, prolog, python, r,
relaxngcompact, rhtml, roff, ruby, rust, scala, scheme, sci, sed, sgml, sql,
sqlmysql, sqlpostgresql, tcl, texinfo, verilog, vhdl, xml, xorg, xslt, xul,
yacc, yaml
Default user data directory: /Users/macbookpro/.pandoc
Copyright (C) 2006-2013 John MacFarlane
Web:  http://johnmacfarlane.net/pandoc
This is free software; see the source for copying conditions.   There is nowarranty, not even for merchantability or fitness for a particular purpose.

こんなのが出たら成功。

使い方

基本的には本家の例を見ればわかる
自分の場合、Markdown形式のファイルをTextileに変換したいので、

 pandoc -s hogehohe.md -o hogehohe.textile

とやるだけ。

便利。おためしあれ。

43
41
3

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
43
41