Skip to content

Instantly share code, notes, and snippets.

@criswell
Created September 22, 2016 13:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save criswell/62a570ceb1fba5a92d25dc4efed5b839 to your computer and use it in GitHub Desktop.
Save criswell/62a570ceb1fba5a92d25dc4efed5b839 to your computer and use it in GitHub Desktop.
namespace :book do
desc 'build the book'
task :build do
puts "Generating EPub..."
`bundle exec asciidoctor-epub3 -a stem main.asc`
puts "> Epub output at main.epub"
puts "Generating Mobi..."
`bundle exec asciidoctor-epub3 -a stem -a ebook-format=kf8 main.asc`
puts "> Mobi output at main.mobi"
puts "Generating PDF..."
`bundle exec asciidoctor-pdf -a stem main.asc`
puts "> PDF output at main.pdf"
end
end
task :default => "book:build"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment