Skip to content

PDF generation doesn't respect "resources" configuration attribute #291

Open
@ge0ffrey

Description

Using the "resources" element in the plugin configuration, we can grab images from 2 directories. We use this to include shared images and a book-specific images. This works perfectly for the html output.

However for the PDF output, configured like this:

              <goals>
                <goal>process-asciidoc</goal>
              </goals>
              <configuration>
                <backend>pdf</backend>
                <resources>
                  <resource>
                    <directory>src/main/asciidoc</directory>
                  </resource>
                  <resource>
                    <directory>${project.basedir}/../shared-kie-docs/src/main/asciidoc</directory>
                  </resource>
                </resources>
                <sourceDocumentName>index.adoc</sourceDocumentName>
                <outputDirectory>${project.build.directory}/generated-docs/pdf</outputDirectory>
              </configuration>

The images end up broken in the pdf and the maven console shows messages like these for images not residing in src/main/asciidoc:

  asciidoctor: WARNING: image to embed not found or not readable: /home/.../kie-docs/docs/optaplanner-wb-es-docs/src/main/asciidoc/KieServer/kie-server-simple-architecture.png
asciidoctor: WARNING: image to embed not found or not readable: /home/.../kie-docs/docs/optaplanner-wb-es-docs/src/main/asciidoc/KieServer/kie-server-architecture.png

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions