I have a Maven project that generates a zip file with maven-assembly-plugin on mvn package
MyProy
|--pom
|--src/...
|--target
|---MyProy-something-1.0.0-SNAPSHOT-zip (contains /1.0.0-SNAPSHOT/...)
I created a Jenkins job and configured a shell script execution as a post step. This script copies the zip to a folder (/something) and unzips it
|-/something
|---1.0.0-SNAPSHOT
|---...
This works fine for builds. However I want to do the same when I launch a release. I installed Jenkins release plugin and in "configure release build" I added this tasks:
- Before release build -> Maven task
mvn release:prepare - After successful release build -> Maven task
mvn release:perform - After successful release build -> Execute shell script - Copy zip and unzip.
I see the mvn release:perform execute correctly, for instance with version 1.0.0 but the problem is that when the script (3.) is launched it applies to the next development version (1.0.1-SNAPSHOT) instead of the release version (1.0.0).