Last active
July 18, 2017 13:52
-
-
Save abelsromero/bc0b0e1e4b2353de986c to your computer and use it in GitHub Desktop.
Asciidoctorj + diagram + pdf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | |
<modelVersion>4.0.0</modelVersion> | |
<groupId>org.asciidoctor.maven</groupId> | |
<artifactId>asciidoctor-diagram-example</artifactId> | |
<version>1.0.0-SNAPSHOT</version> | |
<name>Asciidoctor Diagram Maven example</name> | |
<description>An example project that demonstrates how to integrate Asciidoctor Diagram with the Asciidoctor Maven plugin.</description> | |
<properties> | |
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> | |
<asciidoctor.maven.plugin.version>1.5.4-SNAPSHOT</asciidoctor.maven.plugin.version> | |
<asciidoctorj.version>1.5.4</asciidoctorj.version> | |
<asciidoctorj.diagram.version>1.3.1</asciidoctorj.diagram.version> | |
<jruby.version>1.7.21</jruby.version> | |
<asciidoctorj.pdf.version>1.5.0-alpha.11</asciidoctorj.pdf.version> | |
</properties> | |
<build> | |
<defaultGoal>process-resources</defaultGoal> | |
<plugins> | |
<plugin> | |
<groupId>org.asciidoctor</groupId> | |
<artifactId>asciidoctor-maven-plugin</artifactId> | |
<version>${asciidoctor.maven.plugin.version}</version> | |
<dependencies> | |
<!-- Comment this section to use the default jruby artifact provided by the plugin --> | |
<!-- | |
<dependency> | |
<groupId>org.jruby</groupId> | |
<artifactId>jruby-complete</artifactId> | |
<version>${jruby.version}</version> | |
</dependency> | |
--> | |
<!-- Comment this section to use the default AsciidoctorJ artifact provided by the plugin --> | |
<dependency> | |
<groupId>org.asciidoctor</groupId> | |
<artifactId>asciidoctorj</artifactId> | |
<version>${asciidoctorj.version}</version> | |
</dependency> | |
<dependency> | |
<groupId>org.asciidoctor</groupId> | |
<artifactId>asciidoctorj-diagram</artifactId> | |
<version>${asciidoctorj.diagram.version}</version> | |
</dependency> | |
<dependency> | |
<groupId>org.asciidoctor</groupId> | |
<artifactId>asciidoctorj-pdf</artifactId> | |
<version>${asciidoctorj.pdf.version}</version> | |
</dependency> | |
</dependencies> | |
<configuration> | |
<sourceDirectory>src/docs/asciidoc</sourceDirectory> | |
<requires> | |
<require>asciidoctor-diagram</require> | |
</requires> | |
<attributes> | |
</attributes> | |
</configuration> | |
<executions> | |
<execution> | |
<id>generate-pdf-doc</id> | |
<phase>generate-resources</phase> | |
<goals> | |
<goal>process-asciidoc</goal> | |
</goals> | |
<configuration> | |
<backend>pdf</backend> | |
<attributes> | |
<imagesdir>${project.build.directory}/generated-docs/images</imagesdir> | |
<!-- In case a different path is used for the output, imagesoutdit must be set to the same as imagesdir --> | |
<!--<imagesoutdir>${project.build.directory}/generated-docs/images</imagesoutdir>--> | |
<toc>left</toc> | |
<icons>font</icons> | |
<sectanchors>true</sectanchors> | |
<idprefix/> | |
<idseparator>-</idseparator> | |
</attributes> | |
</configuration> | |
</execution> | |
</executions> | |
</plugin> | |
</plugins> | |
</build> | |
</project> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thank you very much!