You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "elharo (via GitHub)" <gi...@apache.org> on 2026/08/19 12:35:22 UTC
[I] Null classifier produces trailing dash in output filename [maven-mapping]
elharo opened a new issue, #65:
URL: https://github.com/apache/maven-mapping/issues/65
## Description
When an artifact has a null classifier and the mapping expression uses `@{classifier}@` (e.g. `DEFAULT_FILE_NAME_MAPPING_CLASSIFIER`), the output filename contains a trailing dash:
```
maven-test-lib-1.0-.jar
^ trailing dash
```
This happens because `DashClassifierValueSource` sets `classifier` to `""` when the classifier is null (`DashClassifierValueSource.java:69`).
The `@{dashClassifier?}@` variant handles this correctly (produces empty string with no dash), making the non-`?` variant inconsistent.
## Expected behavior
Users of `DEFAULT_FILE_NAME_MAPPING_CLASSIFIER` likely expect that a null classifier either omits the classifier segment entirely, or at least does not leave a dangling dash.
## Relevant code
`DashClassifierValueSource.java:59-72`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Null classifier produces trailing dash in output filename [maven-mapping]
Posted by "elharo (via GitHub)" <gi...@apache.org>.
elharo closed issue #65: Null classifier produces trailing dash in output filename
URL: https://github.com/apache/maven-mapping/issues/65
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org