versions-maven-plugin: revert dependencies from test snapshot back to latest release

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

versions-maven-plugin: revert dependencies from test snapshot back to latest release

Tsernetsov, Oleg / Kuehne + Nagel / TLL

Hi,

 

Once project properties have been updated to use latest snapshots (1.2.0-SNAPSHOT) with "versions:update-properties -DallowSnapshots=true", it is no longer possible to revert the project back to usage of latest  releases (1.1.0).

 

mvn versions:display-property-updates -DallowSnapshots=true

 

[INFO] The following version property updates are available:

[INFO]   ${component1.version} ................. 1.1.0 -> 1.2.0-SNAPSHOT

[INFO]   ${component2.version} ................. 1.1.0 -> 1.2.0-SNAPSHOT

[INFO]   ${component3.version} ................. 1.1.0 -> 1.2.0-SNAPSHOT

 

mvn versions:update-properties -DallowSnapshots=true

 

mvn versions:display-property-updates -DallowSnapshots=false

 

The following version properties are referencing the newest available version:

[INFO]   ${component1.version} .......................... 1.2.0-SNAPSHOT

[INFO]   ${component2.version} .......................... 1.2.0-SNAPSHOT

[INFO]   ${component3.version} .......................... 1.2.0-SNAPSHOT

[INFO] All version properties are referencing the newest version available.

 

I need snapshots for development, in particular to enable "navigate to code" and "search for usages" in Eclipse workspace, but during release phase I would want to make sure no SNAPSHOT dependencies accidentally go to the release package. Is it possible to revert properties back from snapshots to latest release versions?

 

Regards,

Oleg

 


Kühne + Nagel (AG & Co.) KG, Geschäftsleitung: Hans-Georg Brinkmann (Vors.), Dirk Blesius, Reiner Heiken, Holger Ketz (Stellv.), Jan-Hendrik Köstergarten (Stellv.), Bruno Mang, Christian Marnetté, Jens Wollesen, Sitz: Bremen, Registergericht: Bremen, HRA 21928, USt-IdNr.: DE 812773878, Persönlich haftende Gesellschaft: Kühne & Nagel A.G., Sitz: Contern/Luxemburg Geschäftsführender Verwaltungsrat: Karl Gernandt