deploy-file incompatible with "CI-friendly" versions
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 42/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- java
- Domain
- build-system
Research direction
Start with the deploy-file goal and the Maven CI Friendly Versions guide, then inspect how it reads pom.xml and the adjacent pom.properties. Confirm the desired precedence between resolved properties and POM values, and verify that an artifact built with -Drevision=1.2.3 can be deployed with the resolved coordinates.
Written by the indexing model from the issue text.
Description
Affected version
3.1.4
Bug description
The deploy-file goal is very helpful in trying to use an embedded POM whenever it is present (only) with a JAR. To that extent, indeed, #583 / https://issues.apache.org/jira/browse/MDEPLOY-178 seems to have been resolved.
Alas, the implementation is not compatible with Maven CI Friendly Versions,
https://maven.apache.org/guides/mini/guide-maven-ci-friendly.html
Fundamentally, when using Maven CI Friendly Versions, the <version> element of the pom.xml does not contain the final version of the artifact, but will contain variables (properties) for substitution - for instance ${revision} -, yielding
<version>${revision}</version>
as the version.
And that is something that deploy-file does not like, for obvious reasons.
Instead of (only) looking at the pom.xml content, deploy-file should also look at the content found in the adjacent file pom.properties which contains
artifactId=test-artifact
groupId=test.groupid
version=1.2.3
i.e. the resolved version information (having built with mvn -Drevision=1.2.3 clean package)
Thinking further ahead, it may even better if deploy-file preferred any content in pom.properties over whatever is found in pom.xml?
- Dominant language
- Java
- Stars
- 78
- Forks
- 76
- Avg merge
- 2d 5h
- Merged PRs (30d)
- 13
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from apache/maven-deploy-plugin
-
enhancement
Difficulty 5/5 Over a week Newbie friendliness 35/100
apache/maven-deploy-plugin#666 ·
-
enhancement
Difficulty 5/5 Over a week Newbie friendliness 35/100
apache/maven-deploy-plugin#622 ·
-
enhancement
Difficulty 5/5 Over a week Newbie friendliness 35/100
apache/maven-deploy-plugin#122 · 2 reactions ·
-
bug priority:major
Difficulty 3/5 1-2 days Newbie friendliness 45/100
apache/maven-deploy-plugin#412 · 1 reaction ·
-
bug priority:major
Difficulty 4/5 3-5 days Newbie friendliness 20/100
apache/maven-deploy-plugin#206 · 2 comments ·
All issues in apache/maven-deploy-plugin
Similar issues
-
bug
Difficulty 1/5 Under an hour Newbie friendliness 90/100
apache/cloudstack#14222 ·
-
[BUG]茶杯方块在取茶时会引发崩溃 Open
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
1.0.0-alpha2 Type/Improvement
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
wso2/dpdp-accelerator#272 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
infinispan/infinispan#18150 ·
-
area/frontend
Difficulty 2/5 1-3 hours Newbie friendliness 65/100