ProGitソースからビルドしたepub文書の画像リンクが壊れている原因が分かった
「Figure 1-1.」を「図1-1.」に翻訳したのが不具合原因だった。
$ vi ja/01-introduction/01-chapter1.markdown
Insert 18333fig0101.png 図1-1. ローカル・バージョン管理図解 ↓ Insert 18333fig0101.png Figure 図1-1. ローカル・バージョン管理図解
以下の処理で置換に失敗している。
$ vi makeebooks
Dir[File.join(dir, '**', '*.markdown')].sort.each do |input| puts "processing #{input}" content = File.read(input) content.gsub!(/Insert\s+(.*)(\.png)\s*\n?\s*#{figure_title}\s+(.*)/, '![\3](figures/\1-tn\2 "\3")') book_content << RDiscount.new(content).to_html end
修正してpullrequest送ってみよう。まずはやり方を調べる。