pdf2htmlEX項目路徑:https://github.com/coolwanglu/pdf2htmlEX
Linux上安裝:
詳見上述路徑,需要安裝docker,然后直接命令調用即可。
Mac上安裝:
$ brew install poppler
使用:
# 默認輸出 (生成多個互相嵌套的html文件,以及多個圖片 $ pdftohtml sample.pdf sample.html # 生成"復雜"排版,其實就是更精確排版的意思 --complex $ pdftohtml -c sample.pdf sample.html # 指定第一頁至最后一頁區間:first-last $ pdftohtml -f 1 -l 2 sample.pdf sample.html