Support imagesdir
See original GitHub issueSteps to reproduce:
- Have a simple Asciidoc file with
:imagesdir: ./images
- Add an image in the
images/
subdirectory. - Include the image from the AsciiDoc file, e.g.
image::myimage.png[My Image]
Expected results:
- Image gets picked up by the Confluence Publisher from
images/myimage.png
- No error message about the image.
Actual results:
- Image is not picked up, it doesn’t show in the Confluence page.
- There is an error message while publishing:
Exception in thread "main" java.lang.RuntimeException: Could not find attachment
at org.sahli.asciidoc.confluence.publisher.client.ConfluencePublisher.fileInputStream(ConfluencePublisher.java:195)
at org.sahli.asciidoc.confluence.publisher.client.ConfluencePublisher.addOrUpdateAttachment(ConfluencePublisher.java:159)
at org.sahli.asciidoc.confluence.publisher.client.ConfluencePublisher.lambda$addAttachments$7(ConfluencePublisher.java:144)
at java.util.HashMap.forEach(HashMap.java:1289)
at org.sahli.asciidoc.confluence.publisher.client.ConfluencePublisher.addAttachments(ConfluencePublisher.java:144)
at org.sahli.asciidoc.confluence.publisher.client.ConfluencePublisher.lambda$startPublishingUnderAncestorId$0(ConfluencePublisher.java:82)
at java.util.ArrayList.forEach(ArrayList.java:1255)
at org.sahli.asciidoc.confluence.publisher.client.ConfluencePublisher.startPublishingUnderAncestorId(ConfluencePublisher.java:77)
at org.sahli.asciidoc.confluence.publisher.client.ConfluencePublisher.publish(ConfluencePublisher.java:70)
at org.sahli.asciidoc.confluence.publisher.cli.AsciidocConfluencePublisherCommandLineClient.main(AsciidocConfluencePublisherCommandLineClient.java:70)
Caused by: java.io.FileNotFoundException: /tmp/confluence-publisher3122701931061118065/assets/92190f5d2abd7f24e065a5c4632d557b7503363da1bef7d9532a24162e9dbdcb/myimage.png (No such file or directory)
at java.io.FileInputStream.open0(Native Method)
at java.io.FileInputStream.open(FileInputStream.java:195)
at java.io.FileInputStream.<init>(FileInputStream.java:138)
at org.sahli.asciidoc.confluence.publisher.client.ConfluencePublisher.fileInputStream(ConfluencePublisher.java:193)
... 9 more
Issue Analytics
- State:
- Created 5 years ago
- Reactions:1
- Comments:5 (1 by maintainers)
Top Results From Across the Web
Support imagesDir in plugin configuration · Issue #190
You manage the path to the images catalog (imagesdir) in each directory that contains AsciiDoc source files. (In other words, where am I...
Read more >Image Paths and Formats
Image paths can be relative to the imagesdir or absolute. ... Image formats; Support for additional image file formats; Fonts in SVG images....
Read more >Images Directory and Files
The source files for images are stored in an images family directory. Antora supports the PNG, JPG, SVG, and GIF (static and animated)...
Read more >ContrastBrightnessIntensityCom...
Support for 12 and 16-bit grayscale and 48 and 64-bit color images is available only ... Jpeg, 24); } static class LEAD_VARS {...
Read more >Sitefinity CMS 3.x and older versions: ImagesDir Property
Documentation about Sitefinity CMS 3.x and older versions: ImagesDir Property in . Get the help you need online.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Any updates?
Would it perhaps be possible to resolve the
imagesdir
attribute first and then match the resulting image paths against the directories with AsciiDoc files and thus build lists of images belonging to documents?