Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Markdown to LaTeX
Search
Kaneko Tatsuya
April 14, 2013
Technology
1
1.5k
Markdown to LaTeX
Markdown to LaTeX
Kaneko Tatsuya
April 14, 2013
Tweet
Share
More Decks by Kaneko Tatsuya
See All by Kaneko Tatsuya
キャリアを充実させる『カギ』に!PR TIMES CTO金子達哉から学ぶアウトプット術 / output_method
catatsuy
0
570
ISUCONの情報共有にはこれ!notify_slack!/isucon_notify_slack
catatsuy
1
1k
ISUCON6本選のベンチマークでconsulを使用してクラスタを構築した話 / isucon6-night
catatsuy
2
1.2k
ユニクロの レジから学ぶ Goroutine #yapc8oji #yapc8ojiA /uniqlo_golang
catatsuy
6
2.3k
社内ISUCONオープニング/private-isu-opening
catatsuy
0
9.9k
ピクシブ社内広告サーバーでのGoの開発・運用 #gocon /p_ads_server_gocon2015
catatsuy
10
11k
fluentdで大量のログを Google BigQueryに送ってみた #fluentdmeetup /send_a_log_to_bigquery_with_fluentd
catatsuy
1
4.2k
『pixivエンジニアが教えるプログラミング入門』出版記念特別編基調講演
catatsuy
3
1.9k
ピクシブ広告サーバー開発・運用の軌跡 2015春インターン講義資料
catatsuy
17
11k
Other Decks in Technology
See All in Technology
AndroidアプリエンジニアもMCPを触ろう
kgmyshin
2
650
250510 StepFunctionのテスト自動化始めました vol.1
east_takumi
1
220
ソフトウェアテスト 最初の一歩 〜テスト設計技法をワークで体験しながら学ぶ〜 #JaSSTTokyo / SoftwareTestingFirstStep
nihonbuson
PRO
1
150
Part2 GitHub Copilotってなんだろう
tomokusaba
2
780
20 Years of Domain-Driven Design: What I’ve Learned About DDD
ewolff
1
350
LINE 購物幕後推手
line_developers_tw
PRO
0
450
OPENLOGI Company Profile for engineer
hr01
1
26k
名単体テスト 禁断の傀儡(モック)
iwamot
PRO
1
230
genspark_presentation.pdf
haruki_uiru
1
250
Serverlessだからこそコードと設計にはこだわろう
kenichirokimura
2
990
Why Platform Engineering? - マルチプロダクト・少人数 SRE の壁を越える挑戦 -
nulabinc
PRO
5
410
クラウドネイティブ環境の脅威モデリング
kyohmizu
2
410
Featured
See All Featured
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
656
60k
Cheating the UX When There Is Nothing More to Optimize - PixelPioneers
stephaniewalter
280
13k
The Invisible Side of Design
smashingmag
299
50k
GraphQLとの向き合い方2022年版
quramy
46
14k
Producing Creativity
orderedlist
PRO
344
40k
Designing for humans not robots
tammielis
253
25k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
507
140k
Java REST API Framework Comparison - PWX 2021
mraible
31
8.6k
Measuring & Analyzing Core Web Vitals
bluesmoon
7
420
Why Our Code Smells
bkeepers
PRO
336
57k
Stop Working from a Prison Cell
hatefulcrawdad
268
20k
Faster Mobile Websites
deanohume
307
31k
Transcript
Markdown to L ATEX ۚࢠୡ࠸ (id:catatsuy) April 14, 2013
ࣗݾհ • ۚࢠୡ࠸ • 〤〛〟 ID: catatsuy • twitter: catatsuy
URL: • http://www.catatsuy.org • http://blog.catatsuy.org • https://matw.co
ॴଐ • ౦ژۀେֶʢʺి௨େʣ • ใֶՊ 4 ʢ9 ݄ଔۀ༧ఆʣ • ٢ݚڀࣨ
• ぢアゃゔがのぎがずふぜばを • C++11 ্〜まがへげこぎهड़〣てゎゔ゛がてゖアぇ『 DSL ぇఏڙ『ぐゅ゙ぇߴԽ『ݚڀぇ「〛 ⿶〳『ʢ。〟〣〜ུʣ
ब৬׆ಈ • 〤〛〟ぐアのがア 2012 • pixiv ぐアのがア
10 ݄〾 〭ʂ
લճ〣 Dentoo.LT Acme::MorningMusume 〣ぇ「〳「〔 http://blog.catatsuy.org/a/256
ଔۀ「〔⿶
ଔۀจ ʢ8 ݄ఏग़〣〔〶ʣ ઈࢍ⿶ࠐ〴〟⿸ˑ
ಥવ〣ࢮܐએࠂ
ଔ〝⿶⿺〥. . . I ♡ L ATEX
L ATEX • \verb/gcc/ 〝ॻ。〣໘ • \begin{} - \end{} 〜ғ⿸〣໘
• ࠷ॳ〣ゆ゙ぎアゅ゚⿸》⿶
࣌〤ܰྔろがぜぎひゆ〭 L ATEX HTML ⇒ Markdown wiki ه๏ 〤〛〟ه๏
I ♡ Markdown • Github 〟〞〜࠾༻ • ిࢠゐが゚〾〣০〾ண • ւ֎〣ਓ〠〤ײత〾「⿶
• てアゆ゚〠ॻ々 • ֤ݴޠ〜むがつが࣮《ぁ〛⿶
ࠓճ〣のぐぷ゚ Markdown to L ATEX
Pandoc • ろがぜぎひゆݴޠ〣૬ޓมびが゚ • ؔܕݴޠ haskell 〜࣮ • ػೳ〉〝〠៉ྷ〠ゑでゔが゚Խ《ぁ〛⿶ •
ଟ࠼〟やさがろひぷ〠ରԠ • Markdown ⇒ L A TEX 〷Մೳ
Pandoc ぐアとぷが゚ Ubuntu: sudo apt-get install haskell-platform Mac: brew install
ghc brew install haskell-platform common: cabal update cabal install pandoc # ~/.cabal/bin/ ぶく゛ぜぷ゙ҎԼ〠 PATH ぇ௨『
Pandoc 〣⿶ํ # ຊจ〣〴 pandoc input.md -o output.tex # ふアゆ゛がぷࠐ〴
pandoc -s input.md -o output.tex # beamerʢゆ゛にアʣग़ྗ pandoc -t beamer input.md -o output.tex # มࢦఆ pandoc -V fontsize=12Q input.md -o output.tex
Pandoc 〣 • ‘gcc‘ 〝ॻ。〝 \texttt{gcc} 〠《ぁ〛「〳⿸ • ຊ〤 \verb+gcc+
〝〠「〛ཉ「⿶ • ふアゆ゛がぷຊ〣 L A TEX 々〜〤〟⿶
Github 〜 Fork 「〳「〔ʂ git clone git://github.com/catatsuy/pandoc.git cd pandoc git
submodule init git submodule update # git://github.com/catatsuy/pandoc-templates.git # data/templates ҎԼ〠 clone 《ぁ
‘ ‘ 〣ڍಈぇม⿺ src/Text/Pandoc/Writers/LaTeX.hs - rawCode = liftM (text .
(\s -> "\\texttt{" ++ s ++ "}")) - $ stringToLaTeX False str + rawCode = liftM (text . (\s -> "\\verb‘" ++ s ++ "‘")) + $ stringToLaTeX True str
ふアゆ゛がぷ • ผ゙れでぷ゙ʢgit submoduleʣ • data/templates ҎԼ〣 default.latex • $
. . . $ 〜มల։ • ม〤 -V ざゆてゖア〜『
ふアゆ゛がぷ࡞れぐアぷ • ಡ〴ࠐ〵むひたがで〟〞〤࠷খݶ〠 • --include-in-header header.tex 〝「〛Ճ むひたがで〹༨നઃఆ〟〞ぇผやきぐ゚〠〜
cabal-dev • cabal 〤 ~/.cabal/ ҎԼ〠ぐアとぷが゚『 • 『〜〠ຊՈ〣 pandoc 〤ぐアとぷが゚ࡁ〴
• じ゛アぷぶく゛ぜぷ゙্〜ぢアむぐ゚「〔⿶ cabal install cabal-dev cd pandoc cabal-dev install --sandbox=. # pandoc/bin/ ҎԼ〠࣮ߦやきぐ゚ग़ྗ《ぁ
〘〛〴〛〘〔 • গ「〜〷ෳࡶ〟〷〣〤 L A TEX 〜ॻ。ඞཁ • Emacs 〣৭々
L A TEX ෦〜ޮ〟⿶ • yatex 〣ڧྗ〟ิػೳ⿺〟⿶ • վߦ「〔〝〈あ〜とらがとೖ〈〝⿴
վળҊ • Markdown 〜 L A TEX 〣จষぇॻ。〣〜〤〟。 L A
TEX 〣จষ্〜 Markdown ه๏ぇ෦త〠⿸〮 • とらがとೖ〘〛〷〣〟⿶ॴ〜վߦ『 # ⿶〣〜 Makefile ࡞ਪ pandoc -f markdown input.tex -o output.tex # yatex 〤ぶやさ゚ぷ〜ࣗಈվߦ「〛「〳⿸〣〜 .emacs 〠Ճ (add-hook ’ yatex-mode-hook ’(lambda () (auto-fill-mode -1)))
վળҊ〣ॴ • 〈ぁ࠷దղ〘〲⿶ • L A TEX やきぐ゚『〘 〿『 • yatex
〷⿺ • Markdown 〠ิ〹৭々⿶〾〟⿶
ܽ • ग़ྗぇҙࣝ「〟〾ॻ。ඞཁ • L A TEX 〣ॻ ํ〠〷ඞཁ • L
A TEX ぇ७ਮ〠ॻ。〟〾ੜ」〟⿶ແବ〟〴ൃੜ
ඞཁ〟 • \\ ॻ々〟⿶ • \linebreak 〹 \newline 〟〞ぇ⿸ඞཁ •
ぢゐアぷぎげぷ % 〜〜 〟⿶ • comment.sty \if0 \fi ぇ⿸
つアゆ゚ ࠓճ〣Ұ࿈〣ྲྀぁぇ࠶ݱ『つアゆ゚ github.com/catatsuy/mdtolatex_sample Makefile 〟〞ࢀߟ〠「〛。〕《⿶
ࠓޙ〣༧ఆ • ଔぇ Markdown 〜ॻ 〳『 • 〒〣্〜〘〔ぇڞ༗「〛⿶ 〳『 • Markdown 〜ଔॻ 〳「〼⿸