diff options
author | Florian Zschocke <f.zschocke+git@gmail.com> | 2021-12-16 23:41:42 +0100 |
---|---|---|
committer | Florian Zschocke <f.zschocke+git@gmail.com> | 2022-02-01 22:58:30 +0100 |
commit | a35868ddfb30c5e76ad6695f845045e6273b7332 (patch) | |
tree | ceb37e49353cb5c4af9f2cbedeab7082a440d3c4 | |
parent | 7e89c337bc22c825e3251ad418f6bbaa3dfdbac8 (diff) | |
download | gitblit-a35868ddfb30c5e76ad6695f845045e6273b7332.tar.gz gitblit-a35868ddfb30c5e76ad6695f845045e6273b7332.zip |
build: Add target to determine and report release version
-rw-r--r-- | build.xml | 32 |
1 files changed, 30 insertions, 2 deletions
@@ -863,6 +863,34 @@ </target>
+
+ <!--
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ Determine the release version and tag name.
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ -->
+ <target name="determineReleaseVersion" depends="prepare" description="determine the release version and tag name">
+ <!-- release -->
+ <property name="dryrun" value="true" />
+ <mx:version stage="release" dryrun="${dryrun}" />
+ <property name="project.tag" value="v${project.version}" />
+
+ <!-- output version information for other scripts/programs to pick up -->
+ <mx:if>
+ <and>
+ <isset property="versionInfo" />
+ <not><equals arg1="${versionInfo}" arg2="" trim="true"/></not>
+ </and>
+ <then>
+ <echo file="${basedir}/${versionInfo}">
+GBLT_RELEASE_VERSION=${project.version}
+GBLT_RELEASE_TAG=${project.tag}
+</echo>
+ </then>
+ </mx:if>
+ </target>
+
+
<!--
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Tag a new version and prepare for the next development cycle.
@@ -889,8 +917,8 @@ </and>
<then>
<echo file="${basedir}/${versionInfo}">
-GB_RELEASE_VERSION=${project.version}
-GB_RELEASE_TAG=${project.tag}
+GBLT_RELEASE_VERSION=${project.version}
+GBLT_RELEASE_TAG=${project.tag}
</echo>
</then>
</mx:if>
|