asciidoctor / asciidoctor-maven-plugin

A Maven plugin that uses Asciidoctor via JRuby to process AsciiDoc source files within the project.
http://asciidoctor.org
Apache License 2.0
318 stars 122 forks source link

(v2.2.x) Fix empty destination path calculation for validation #730

Closed abelsromero closed 10 months ago

abelsromero commented 10 months ago

What kind of change does this PR introduce? (check at least one)

What is the goal of this pull request?

Fix #728 Also improve message. We cannot get the exact name without duplication asciidoctor core logic, but now when outputFile is not set simply wildcard will be displayed instead of the source extension to avoid confusion:

[warn] Duplicated destination found: overwriting file: /.../path/single-output.*

Are there any alternative ways to implement this?

We could only check for toDir (as done in main branch) but that would break builds using older AsciidoctorJ versions.

Are there any implications of this pull request? Anything a user must know?

no

Is it related to an existing issue?

- [x] Yes - [ ] No *Finally, please add a corresponding entry to CHANGELOG.adoc*