Check both -snapshot and not -snapshot in release/staging.

This commit is contained in:
Manuele Simi 2020-01-27 09:35:33 -05:00
parent d8aacfd01c
commit cad1e191f7
1 changed files with 28 additions and 0 deletions

28
pom.xml
View File

@ -331,6 +331,20 @@
<value>${project.version}</value>
<regex>.*-SNAPSHOT$</regex>
<replacement>true</replacement>
<failIfNoMatch>false</failIfNoMatch>
</configuration>
</execution>
<execution>
<!--fails if SNAPSHOT was used-->
<id>fail-helper-regex-is-snapshot-used</id>
<phase>validate</phase>
<goals>
<goal>regex-property</goal>
</goals>
<configuration>
<name>fail.when.is.snapshot.used</name>
<value>${project.version}</value>
<regex>^((?!.*-SNAPSHOT).)*$</regex>
<failIfNoMatch>true</failIfNoMatch>
</configuration>
</execution>
@ -440,6 +454,20 @@
<value>${project.version}</value>
<regex>.*-SNAPSHOT$</regex>
<replacement>true</replacement>
<failIfNoMatch>false</failIfNoMatch>
</configuration>
</execution>
<execution>
<!--fails if SNAPSHOT was used-->
<id>fail-helper-regex-is-snapshot-used</id>
<phase>validate</phase>
<goals>
<goal>regex-property</goal>
</goals>
<configuration>
<name>fail.when.is.snapshot.used</name>
<value>${project.version}</value>
<regex>^((?!.*-SNAPSHOT).)*$</regex>
<failIfNoMatch>true</failIfNoMatch>
</configuration>
</execution>