Archit Arora
Archit Arora

Reputation: 2626

Append build number to maven artifact when it's uploaded to Artifactory

I have created a local maven repo with the following configuration - enter image description here

Now when I upload and artifact using mvn deploy the artifacts (a .zip package and a POM file) are uploaded with their names appended with the timestamp and a number as a suffix. I want to know what these single digit numbers at the very end are. Can I control them? Can I have say build numbers at the end instead of these auto generated numbers.

Please note that I want to replace the single digits after the timestamp with build numbers.

Cheers

enter image description here

Upvotes: 0

Views: 290

Answers (1)

J Fabian Meier
J Fabian Meier

Reputation: 35805

The format of Snapshot numbers is fixed and cannot be changed.

If you need a custom number format, you need to construct it yourself, e.g. you can use version numbers of the form 1.2.3-${buildnumber}, but they will not be Snapshots in the sense of Maven.

Upvotes: 1

Related Questions