• Stars
    star
    203
  • Rank 192,890 (Top 4 %)
  • Language
    Ruby
  • License
    MIT License
  • Created over 10 years ago
  • Updated about 1 year ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

๐Ÿ“˜ Asciidoctor EPUB3 is a set of Asciidoctor extensions for converting AsciiDoc to EPUB3 & KF8/MOBI

Asciidoctor EPUB3: A native EPUB3 converter for AsciiDoc

project chat Latest Release GitHub Actions

Asciidoctor EPUB3 is a set of Asciidoctor extensions for converting AsciiDoc documents directly to the EPUB3 and KF8/MOBI e-book formats.

Documentation

Detailed installation and usage instructions can be found on the Asciidoctor Docs site.

Installation

Asciidoctor EPUB3 is published on RubyGems.org. Asciidoctor EPUB3 requires Ruby 2.3 or newer. You can install the published gem using the following command:

$ gem install asciidoctor-epub3

Assuming the gem and its dependencies install properly, verify you can run the asciidoctor-epub3 script:

$ asciidoctor-epub3 -v

If you see the version of Asciidoctor EPUB3 printed, youโ€™re ready to use Asciidoctor EPUB3.

Usage

Converting an AsciiDoc document to EPUB3 is as simple as passing your document to the asciidoctor-epub3 command. This command should be available on your PATH if you installed the asciidoctor-epub3 gem. Otherwise, you can find the command in the bin folder of the project. We also recommend specifying an output directory using the -D option flag.

$ asciidoctor-epub3 -D output path/to/book.adoc

When the script completes, youโ€™ll see the file book.epub appear in the output directory. Open that file with an EPUB3 reader to view the result.

You may also produce KF8/MOBI file by setting ebook-format attribute to kf8.

$ asciidoctor-epub3 -D output -a ebook-format=kf8 path/to/book.adoc

When the script completes, the file book.mobi will appear in output directory.

Contributing

In the spirit of free software, everyone is encouraged to help improve this project.

To contribute code, simply fork the project on GitHub, hack away and send a pull request with your proposed changes.

Feel free to use the issue tracker or {uri-discuss}[Asciidoctor mailing list] to provide feedback or suggestions in other ways.

Development

To help develop Asciidoctor EPUB3, or to simply test drive the development version, you need to get the source from GitHub. Follow the instructions below to learn how to clone the source and run it from your local copy.

Retrieve the Source Code

You can retrieve Asciidoctor EPUB3 in one of two ways:

  1. Clone the git repository

  2. Download a zip archive of the repository

Option 1: Fetch Using git clone

If you want to clone the git repository, simply copy the {uri-repo}[GitHub repository URL] and pass it to the git clone command:

$ git clone {uri-repo}

Next, change to the project directory:

$ cd asciidoctor-epub3

Option 2: Download the Archive

If you want to download a zip archive, click on the btn:[[cloud download] button on the right-hand side of the repository page on GitHub. Once the download finishes, extract the archive, open a console and change to that directory.

Tip
Instead of working out of the asciidoctor-epub3 directory, you can simply add the absolute path of the bin directory to your PATH environment variable.

Weโ€™ll leverage the project configuration to install the necessary dependencies.

Prepare RVM (optional step)

If youโ€™re using RVM, we recommend creating a new gemset to work with Asciidoctor EPUB3:

$ rvm use 2.2@asciidoctor-epub3-dev --create

We like RVM because it keeps the dependencies required by various projects isolated.

Install the Dependencies

The dependencies needed to use Asciidoctor EPUB3 are defined in the Gemfile at the root of the project. We can use Bundler to install the dependencies for us.

To check if you have Bundler available, use the bundle command to query the version installed:

$ bundle --version

If itโ€™s not installed, use the gem command to install it.

$ gem install bundler

Then use the bundle command to install the project dependencies:

$ bundle
Note
You need to call bundle from the project directory so that it can find the Gemfile.

Build and Install the Gem

Now that the dependencies are installed, you can build and install the gem.

Use the Rake build tool to build and install the gem (into the current RVM gemset or into the system if not using RVM):

$ rake install:local

The build will report that it built the gem into the pkg directory and that it installed the gem.

Once the development version of the gem is installed, you can run Asciidoctor EPUB3 by invoking the asciidoctor-epub3 script:

$ asciidoctor-epub3 -v

If you see the version of Asciidoctor EPUB3 printed to your console, youโ€™re ready to use Asciidoctor EPUB3!

Shortcut: Run the Launch Script Directly

Assuming all the required gems install properly, you can run the asciidoctor-epub3 script directly out of the project folder using either:

$ bin/asciidoctor-epub3 -v

or

$ bundle exec bin/asciidoctor-epub3 -v

Youโ€™re now ready to test drive the development version of Asciidoctor EPUB3!

Jump back to [Getting Started] to learn how to create an AsciiDoc document and convert it to EPUB3.

Fonts

Asciidoctor EPUB3 embeds a set of fonts and font icons. The themeโ€™s fonts are located in the data/fonts directory.

The M+ Outline fonts are used for titles, headings, literal (monospace) text, and annotation numbers. The body text uses Noto Serif. Admonition icons and the end-of-chapter mark are from the Font Awesome icon font. Refer to the NOTICE.adoc file for further information about the fonts.

Planned Features and Work In Progress

Authors

Asciidoctor EPUB3 was written by Dan Allen and Sarah White of OpenDevise on behalf of the Asciidoctor Project.

Copyright ยฉ 2014-2021 OpenDevise Inc. and the Asciidoctor Project. Free use of this software is granted under the terms of the MIT License.

For the full text of the license, see the LICENSE file. Refer to the NOTICE.adoc file for information about third-party Open Source software in use.

More Repositories

1

asciidoctor

๐Ÿ’Ž A fast, open source text processor and publishing toolchain, written in Ruby, for converting AsciiDoc content to HTML 5, DocBook 5, and other formats.
Ruby
4,437
star
2

asciidoctor-pdf

๐Ÿ“ƒ Asciidoctor PDF: A native PDF converter for AsciiDoc based on Asciidoctor and Prawn, written entirely in Ruby.
Ruby
1,089
star
3

asciidoctor.js

๐Ÿ“œ A JavaScript port of Asciidoctor, a modern implementation of AsciiDoc
JavaScript
664
star
4

asciidoctorj

โ˜• Java bindings for Asciidoctor. Asciidoctor on the JVM!
Java
593
star
5

asciidoctor-diagram

โ†”๏ธ Asciidoctor diagram extension, with support for AsciiToSVG, BlockDiag (BlockDiag, SeqDiag, ActDiag, NwDiag), Ditaa, Erd, GraphViz, Mermaid, Msc, PlantUML, Shaape, SvgBob, Syntrax, UMLet, Vega, Vega-Lite and WaveDrom.
Ruby
434
star
6

asciidoctor-intellij-plugin

AsciiDoc plugin for products on the IntelliJ platform (IDEA, RubyMine, etc)
Java
324
star
7

asciidoctor.org

๐ŸŒ Asciidoctor project site. Composed in AsciiDoc. Baked with Awestruct.
SCSS
308
star
8

asciidoctor-maven-plugin

A Maven plugin that uses Asciidoctor via JRuby to process AsciiDoc source files within the project.
Java
298
star
9

jekyll-asciidoc

๐Ÿ’‰ A Jekyll plugin that converts AsciiDoc source files in your site to HTML pages using Asciidoctor.
Ruby
298
star
10

docker-asciidoctor

๐Ÿšข A Docker image for using the Asciidoctor toolchain to process AsciiDoc content
Shell
294
star
11

asciidoctor-vscode

AsciiDoc support for Visual Studio Code using Asciidoctor
TypeScript
281
star
12

asciidoctor-gradle-plugin

A Gradle plugin that uses Asciidoctor via JRuby to process AsciiDoc source files within the project.
Groovy
272
star
13

asciidoctor-reveal.js

๐Ÿ”ฎ A reveal.js converter for Asciidoctor and Asciidoctor.js. Write your slides in AsciiDoc!
HTML
270
star
14

asciidoctor-browser-extension

โšช An extension for web browsers that converts AsciiDoc files to HTML using Asciidoctor.js.
CSS
202
star
15

asciidoctor-maven-examples

A collection of example projects that demonstrates how to use the Asciidoctor Maven plugin.
Java
187
star
16

asciidoctor-stylesheet-factory

!DEPRECATED! This was the utility project for producing the default stylesheet for the HTML converter in Asciidoctor. The source of the default stylesheet now lives in the main Asciidoctor repository.
SCSS
178
star
17

kramdown-asciidoc

A kramdown extension for converting Markdown documents to AsciiDoc.
Ruby
174
star
18

asciidoctor-gradle-examples

A collection of example projects that demonstrates how to use the Asciidoctor Gradle plugin
Java
145
star
19

atom-asciidoc-preview

โš› AsciiDoc preview for the Atom editor.
CoffeeScript
142
star
20

asciidoctor-kroki

Asciidoctor.js extension to convert diagrams to images using Kroki!
JavaScript
124
star
21

asciidoclet

๐Ÿ“‹ A Javadoc Doclet based on Asciidoctor that lets you write Javadoc in the AsciiDoc syntax.
Java
120
star
22

asciidoctor-fopub

A portable DocBook-to-PDF build command that wraps DocBook XSL and Apache FOP
Java
111
star
23

asciidoctor-latex

๐Ÿ“ Add LaTeX features to AsciiDoc & convert AsciiDoc to LaTeX
Ruby
106
star
24

jekyll-asciidoc-quickstart

A template project for creating AsciiDoc-based websites using Jekyll.
CSS
105
star
25

asciidoctor-extensions-lab

A lab for testing and demonstrating Asciidoctor extensions. Please do not use this code in production. If you want to use one of these extensions in your application, create a new project, import the code, and distribute it as a RubyGem. You can then request to make it a top-level project under the Asciidoctor organization.
Ruby
97
star
26

asciidoctor-confluence

Push Asciidoctor file to Confluence
Ruby
80
star
27

asciidoctor-backends

Backends (i.e., templates) for Asciidoctor, a Ruby port of AsciiDoc.
HTML
66
star
28

asciidoctor-bibtex

Add bibtex citation support for asciidoc documents
Ruby
59
star
29

docgist

Render AsciiDoc documents from Gists, GitHub, DropBox and other remote sources in the browser.
CSS
56
star
30

asciidoc-docs

The source files in this repository served as the initial contribution for the AsciiDoc Language specification project at Eclipse. This repository is now archived.
55
star
31

brackets-asciidoc-preview

Live Preview of AsciiDoc for Adobe Brackets
JavaScript
51
star
32

asciidoctor-bespoke

๐Ÿ…ฑ๏ธ An Asciidoctor converter that generates the HTML component of a Bespoke.js presentation from AsciiDoc.
Slim
49
star
33

sublimetext-asciidoc

AsciiDoc Package for SublimeText 3
Python
49
star
34

asciidoctor-mathematical

An extension for Asciidoctor that converts the content of STEM blocks and inline macros using Mathematical.
Ruby
44
star
35

atom-language-asciidoc

โš› AsciiDoc language package for the Atom editor.
CoffeeScript
42
star
36

asciidoctorj-pdf

AsciidoctorJ PDF bundles the Asciidoctor PDF RubyGem (asciidoctor-pdf) so it can be loaded into the JVM using JRuby.
Java
33
star
37

asciidoctor-firefox-addon

๐Ÿบ An add-on for Mozilla Firefox that converts AsciiDoc files to HTML directly in the browser using Asciidoctor.js.
JavaScript
32
star
38

asciidoctorj-screenshot

A set of AsciidoctorJ extensions for adding automated screenshots to an AsciiDoc document.
Groovy
32
star
39

asciidoctor-tabs

An extension for Asciidoctor that adds a tabs block to the AsciiDoc syntax.
Ruby
29
star
40

asciidoctor-lein-plugin

A Leiningen plugin for generating documentation using Asciidoctor
Clojure
26
star
41

asciidoctor-chart

A set of Asciidoctor extensions that add a chart block and block macro to AsciiDoc for including charts in your AsciiDoc document.
Ruby
25
star
42

asciidoctor-reducer

โš—๏ธ A tool to generate a single AsciiDoc document by expanding all the include directives reachable from the parent document.
Ruby
24
star
43

asciimath

Asciimath parser
Ruby
23
star
44

docbookrx

(An early version of) a DocBook to AsciiDoc converter written in Ruby.
Ruby
22
star
45

gitbucket-asciidoctor-plugin

A GitBucket plug-in that provided AsciiDoc rendering capabilities
Scala
18
star
46

asciidoctor-leanpub-converter

A backend for AsciidoctorJ to generate Leanpub-flavoured Markdown
Groovy
16
star
47

codemirror-asciidoc

AsciiDoc mode for CodeMirror
JavaScript
16
star
48

asciidoc-grammar-prototype

โ›” ARCHIVED: An experiment to create of a formal grammar for the AsciiDoc markup language. Work is being continued at https://github.com/Mogztter/asciidoctor-inline-parser.
Java
16
star
49

asciidoctor-cli.js

The Command Line Interface (CLI) for Asciidoctor.js
JavaScript
15
star
50

asciidoctor-documentation-planning

โ›” ARCHIVED: Planning for the documentation that covers the AsciiDoc syntax, the Asciidoctor processor, and various projects in the Asciidoctor ecosystem.
15
star
51

asciidoctorj-groovy-dsl

A Groovy DSL that allows for easy definition of Asciidoctor extensions
Groovy
14
star
52

gulp-asciidoctor

gulp-asciidoctor
JavaScript
14
star
53

asciidoctor-docs-ui

The project that produces the UI (theme & user interactions) for docs.asciidoctor.org.
CSS
12
star
54

docs.asciidoctor.org

The Antora playbook project (i.e., site manifest) for the Asciidoctor documentation site.
JavaScript
11
star
55

asciidoctor-deck.js

โ›” ARCHIVED: deck.js converter templates for Asciidoctor, implemented in Haml
HTML
11
star
56

asciidoctor-doctest

๐Ÿ”จ Test suite for Asciidoctor backends
Ruby
10
star
57

asciidoctorj-reveal.js

AsciidoctorJ Reveal.js bundles the Asciidoctor Reveal.js RubyGem (asciidoctor-revealjs) so it can be loaded into the JVM using JRuby
Java
10
star
58

asciidoctor-ant

๐Ÿœ Ant task to render Asciidoc documentation
Ruby
9
star
59

asciidoctor-diagram-java

Java
9
star
60

asciidoctorj-diagram

AsciidoctorJ Diagram bundles the Asciidoctor Diagram RubyGem (asciidoctor-diagram) so it can be loaded into the JVM using JRuby.
Java
9
star
61

atom-asciidoc-image-helper

โš› Tool to make insertion of images into AsciiDocs easier in the Atom editor.
CoffeeScript
9
star
62

atom-asciidoc-assistant

โš› AsciiDoc Assistant package for the Atom editor.
Shell
9
star
63

asciidoctor-chrome-editor

โ›” ARCHIVED: AsciiDoc Editor inside Chrome!
JavaScript
8
star
64

guard-asciidoc

Guard::AsciiDoc monitors and automatically renders your AsciiDoc documents using Asciidoctor
Ruby
8
star
65

atom-autocomplete-asciidoc

โš› AsciiDoc language autocompletions
CoffeeScript
7
star
66

asciidoctor-docbook.js

DocBook converter for Asciidoctor.js
JavaScript
7
star
67

asciidoctor-mallard

A Mallard 1.0 converter for Asciidoctor
Ruby
6
star
68

asciidoctor-lazybones

Lazybones templates for Asciidoctor projects
Groovy
5
star
69

asciidoctor-fb2

๐Ÿ“• Asciidoctor FB2 is an Asciidoctor extension for converting AsciiDoc to FB2
Ruby
5
star
70

html-pipeline-asciidoc_filter

โ›” ARCHIVED: An AsciiDoc processing filter for html-pipeline based on Asciidoctor.
Ruby
5
star
71

brand

Brand assets and visual identity for the Asciidoctor project
Shell
4
star
72

opal-node-runtime

โšก๏ธ Opal Runtime specifically designed for Asciidoctor
JavaScript
4
star
73

asciidoctor-template.js

โ›”๏ธ DEPRECATED: Generic template backend for Asciidoctor.js
JavaScript
4
star
74

asciidoctor-deb-mirror

A mirror of the asciidoctor deb (Debian) package build in the pkg-ruby-extras package group. DO NOT PUSH CHANGES TO THIS MIRROR.
Ruby
3
star
75

docker-asciidoctorj

Ensure that AsciidoctorJ can be used by apps into a Java Application Server (WildFly AS for now)
Java
3
star
76

asciidoctor-community-docs

Process, policy, and other shared documentation for the Asciidoctor community of projects.
3
star
77

asciidoctorj-chart

AsciidoctorJ Chart bundles the Asciidoctor Chart RubyGem (asciidoctor-chart) so it can be loaded into the JVM using JRuby.
HTML
3
star
78

asciidoctor-grunt-plugin

A Grunt plugin that uses Asciidoctor via Asciidoctor.js to process AsciiDoc source files within the project.
HTML
2
star
79

asciidoctor-rpm-mirror

A mirror of the package spec for the rubygem-asciidoctor (alias: asciidoctor) rpm. DO NOT PUSH CHANGES TO THIS MIRROR.
Ruby
2
star
80

default-to-asciidoc-chrome-extension

You love AsciiDoc and you want it to be the default option, this extension is for you!
JavaScript
2
star
81

asciidoctorj-epub3

AsciidoctorJ EPUB3 bundles the Asciidoctor EPUB3 RubyGem (asciidoctor-epub3) so it can be loaded into the JVM using JRuby.
Java
1
star
82

asciidoctor-docbook45

!DEPRECATED! An Asciidoctor converter that converts AsciiDoc to DocBook 4.5. This converter is community maintained and will not be released. Use the built-in DocBook 5 converter instead.
Ruby
1
star