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
続・パイプを通るPDF
Search
T. MOTOOKA
April 07, 2018
Programming
0
1.1k
続・パイプを通るPDF
ワンライナーでPDFに絵を描きましょう
T. MOTOOKA
April 07, 2018
Tweet
Share
More Decks by T. MOTOOKA
See All by T. MOTOOKA
自動化した処理を止めてしまった話
motooka
0
99
StoredFunctionのすゝめ
motooka
1
96
コメントは英語で書く!
motooka
1
110
TCPポート使い切り事件
motooka
1
470
SVG画像をPHPで生成しよう
motooka
0
1.3k
Working with Database Replications in CakePHP
motooka
1
2.1k
文字とPDFとPDFKit
motooka
2
2.1k
SVG破損事例の解説
motooka
1
760
エラー処理のUIデザイン
motooka
0
1.5k
Other Decks in Programming
See All in Programming
AI Ramen Fight
yusukebe
0
110
React は次の10年を生き残れるか:3つのトレンドから考える
oukayuka
40
15k
テスターからテストエンジニアへ ~新米テストエンジニアが歩んだ9ヶ月振り返り~
non0113
2
240
抽象化という思考のツール - 理解と活用 - / Abstraction-as-a-Tool-for-Thinking
shin1x1
1
620
11年かかって やっとVibe Codingに 時代が追いつきましたね
yimajo
0
150
Streamlitで実現できるようになったこと、実現してくれたこと
ayumu_yamaguchi
2
220
AI Agent 時代のソフトウェア開発を支える AWS Cloud Development Kit (CDK)
konokenj
6
970
AI駆動のマルチエージェントによる業務フロー自動化の設計と実践
h_okkah
0
290
GPUを計算資源として使おう!
primenumber
1
290
「テストは愚直&&網羅的に書くほどよい」という誤解 / Test Smarter, Not Harder
munetoshi
1
220
Hack Claude Code with Claude Code
choplin
8
2.8k
可変変数との向き合い方 $$変数名が踊り出す$$ / php conference Variable variables
gunji
0
230
Featured
See All Featured
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
109
19k
Being A Developer After 40
akosma
90
590k
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
656
60k
Designing for Performance
lara
610
69k
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
7
760
Large-scale JavaScript Application Architecture
addyosmani
512
110k
Bash Introduction
62gerente
613
210k
Optimising Largest Contentful Paint
csswizardry
37
3.3k
What’s in a name? Adding method to the madness
productmarketing
PRO
23
3.6k
Visualization
eitanlees
146
16k
Designing for humans not robots
tammielis
253
25k
Navigating Team Friction
lara
187
15k
Transcript
ଓɾύΠϓΛ௨Δ1%' ୈճγΣϧܳษڧձ -5 CZ5.0500,"
୭ʁ w !U@NPUPPLB w େࡕαςϥΠτͷํ͔Βདྷ·ͨ͠ w झຯɿ47(ඳ͍ͨΓ1%'ॻ͍ͨΓ w ৬ۀ w
1)1ॻ͍ͨΓ42-ॻ͍ͨΓ w ٛͷ 1%'ॻ͍ͨΓ w )FBMUI$IFDLͷ௨Βͳ͍αʔόͷཧऀ w ݩϢʔϑΥχΞϜऀ
None
લճ·Ͱͷ͋Β͢͡ w ୈճγΣϧܳษڧձେࡕαςϥΠτ-5 w *NBHF.BHJDLDPOWFSUͰɺۭͬΆͷ1%'Λ࡞ΕΔ w ͦΕ45%065ʹు͚Δʂʂ w IFBEʹͤϔομ͕ݟ͑Δʢ͓͓͓͓͓ʂʂʂʂʂʣ w
Ԡ༻ͷ༨ɺ͍Ζ͍Ζ͋ΔΑͶʙʙɹ
1%'ΑɺύΠϓΛ௨Εʂ
ۭͬΆͷ1%'Λు͘ convert xc:none -page A4 pdf:-
(IPTU4DSJQUͰ/001 convert xc:none -page A4 pdf:- \ | gs -q
-sOutputFile=- -sDEVICE=pdfwrite -
ઢΛҾ͘ convert xc:none -page A4 pdf:-\ | gs -q -sOutputFile=-
-sDEVICE=pdfwrite \ -c '<< /EndPage { exch pop 2 lt { newpath 200 300 moveto 10 200 rlineto closepath 0.8 0.2 0.1 setrgbcolor stroke true }{false} ifelse } bind >> setpagedevice'\ -
ѹॖ͞ΕͨඳըࢦࣔΛ৳ convert xc:none -page A4 pdf:-\ | gs -q -sOutputFile=-
-sDEVICE=pdfwrite \ -c '<< /EndPage { exch pop 2 lt { newpath 200 300 moveto 10 200 rlineto closepath 100 0 0 setrgbcolor stroke true }{false} ifelse } bind >> setpagedevice'\ -\ | pdftk - output - uncompress
·ͱΊɿͬͨςΫ w *NBHF.BHJDLDPOWFSUɺۭͬΆͷ1%'Λు͚Δ w (IPTU4DSJQU1PTU4DSJQUͰ1%'ʹֆΛඳ͚Δ w QEGUL1%'ͷѹॖσʔλΛ৳Ͱ͖Δ w ͦͷ݁ՌɺMFTTͱ͔ͰඳըίϚϯυͷத͕ݟ͑Δ w
্هͷίϚϯυ܈TUEJOTUEPVUܦ༝Ͱ1%'ΛΓͱΓ Ͱ͖Δ
ࢀߟ̍ɿڥใ w 6CVOUV w *NBHF.BHJDL w (IPTU4DSJQU
ࢀߟ̎ɿڥߏஙྫ DockerΛͬͨྫ • docker run -it -v "$(pwd)/pdf":/pdf \ ubuntu:16.04
bash • exitޙͷ࠶ར༻ docker start -ai $(docker ps -a Ͱݟ͑Δname) • apt update • apt install ghostscript imagemagick pdftk less
ࢀߟ̏ɿ1PTU4DSJQU w 1%'ʹ(IPTU4DSJQUͰֆΛඳ͘ IUUQTTUBDLPWFSqPXDPNB
%%EOF