This Docker container provides:
-
Asciidoctor 1.5.5
-
Asciidoctor PDF 1.5.0.alpha.13
-
Asciidoctor EPUB3 1.5.0.alpha.6
-
Source highlighting using CodeRay or Pygments
Download this repo if you don’t have any project yet:
$ git clone https://github.com/alejandroSuch/asciidoctor-book-template.git bookname
$ cd bookname
Build HTML version:
docker run -it -w /opt/ -v $(pwd):/opt/ --rm alexsuch/asciidoctor asciidoctor -D output book.adoc
Build PDF version:
docker run -it -w /opt/ -v $(pwd):/opt/ --rm alexsuch/asciidoctor asciidoctor-pdf -D output book.adoc
Build EPUB version:
docker run -it -w /opt/ -v $(pwd):/opt/ --rm alexsuch/asciidoctor asciidoctor-epub3 -D output book.adoc
Build Kindle version:
docker run -it -w /opt/ -v $(pwd):/opt/ --rm alexsuch/asciidoctor asciidoctor-epub3 -a ebook-format=kf8 -D output book.adoc
In all cases, result will be stored in output
dir:
$ tree
.
├── README.adoc
├── book-sample.adoc
├── book.adoc
├── chapters
│ └── cjk.adoc
├── images
│ ├── cover.png
│ └── cover.svg
└── output
├── book-kf8.epub
├── book.epub
├── book.html
├── book.mobi
└── book.pdf