blob: fad16815b6e86cd8664fcdca7badc843eb87ab4b [file] [log] [blame]
Marian Harbachebeb1542019-12-13 10:42:46 +01001:linkattrs:
Yuxuan 'fishy' Wang61698b12013-12-20 12:55:51 -08002= Making a Release of a Gerrit Subproject
Martin Fick21e278e2012-02-23 13:45:54 -07003
Edwin Kempinbb8e6252012-07-31 14:30:35 +02004[[make-snapshot]]
Yuxuan 'fishy' Wang61698b12013-12-20 12:55:51 -08005== Make a Snapshot
Martin Fick21e278e2012-02-23 13:45:54 -07006
Edwin Kempinbb8e6252012-07-31 14:30:35 +02007* Build the latest snapshot and install it into the local Maven
8repository:
9+
Michael Ochmannb99feab2016-07-06 14:10:22 +020010----
Edwin Kempinbb8e6252012-07-31 14:30:35 +020011 mvn clean install
Michael Ochmannb99feab2016-07-06 14:10:22 +020012----
Edwin Kempinbb8e6252012-07-31 14:30:35 +020013
14* Test Gerrit with this snapshot locally
Martin Fick21e278e2012-02-23 13:45:54 -070015
16
Yuxuan 'fishy' Wang61698b12013-12-20 12:55:51 -080017== Publish Snapshot
Martin Fick21e278e2012-02-23 13:45:54 -070018
David Pursehouse383a3182013-12-06 13:06:57 +090019If a snapshot for a subproject was created that should be referenced by
20Gerrit while current Gerrit development is ongoing, this snapshot needs
Edwin Kempinbb8e6252012-07-31 14:30:35 +020021to be published.
Martin Fick21e278e2012-02-23 13:45:54 -070022
Edwin Kempinbb8e6252012-07-31 14:30:35 +020023* Make sure you have done the configuration needed for deployment:
24** link:dev-release-deploy-config.html#deploy-configuration-settings-xml[
25Configuration in Maven `settings.xml`]
26** link:dev-release-deploy-config.html#deploy-configuration-subprojects[
27Configuration for Subprojects in `pom.xml`]
Martin Fick21e278e2012-02-23 13:45:54 -070028
Edwin Kempinbb8e6252012-07-31 14:30:35 +020029* Deploy the new snapshot:
30+
Michael Ochmannb99feab2016-07-06 14:10:22 +020031----
Martin Fick21e278e2012-02-23 13:45:54 -070032 mvn deploy
Michael Ochmannb99feab2016-07-06 14:10:22 +020033----
Martin Fick21e278e2012-02-23 13:45:54 -070034
David Pursehouse383a3182013-12-06 13:06:57 +090035* Change the `id`, `bin_sha1`, and `src_sha1` values in the `maven_jar`
Dave Borowitz9c359792017-11-14 08:40:55 -050036for the subproject in `/WORKSPACE` to the `SNAPSHOT` version.
Edwin Kempinbb8e6252012-07-31 14:30:35 +020037+
David Pursehouse383a3182013-12-06 13:06:57 +090038When Gerrit gets released, a release of the subproject has to be done
39and Gerrit has to reference the released subproject version.
Martin Fick21e278e2012-02-23 13:45:54 -070040
Martin Fick21e278e2012-02-23 13:45:54 -070041
Edwin Kempinbb8e6252012-07-31 14:30:35 +020042[[prepare-release]]
Yuxuan 'fishy' Wang61698b12013-12-20 12:55:51 -080043== Prepare the Release
Edwin Kempinbb8e6252012-07-31 14:30:35 +020044
45* link:#make-snapshot[First create (and test) the latest snapshot for
David Pursehouse383a3182013-12-06 13:06:57 +090046the subproject]
Martin Fick21e278e2012-02-23 13:45:54 -070047
David Pursehouse383a3182013-12-06 13:06:57 +090048* Update the top level `pom.xml` in the subproject to reflect
Edwin Kempin67e09dc2012-07-23 10:46:06 +020049the new project version (the exact value of the tag you will create
50below)
Martin Fick21e278e2012-02-23 13:45:54 -070051
Edwin Kempinbb8e6252012-07-31 14:30:35 +020052* Create the Release Tag
53+
Michael Ochmannb99feab2016-07-06 14:10:22 +020054----
55 git tag -a -m "prolog-cafe 1.3" v1.3
56----
Martin Fickec31ff42012-06-23 11:35:39 -060057
Edwin Kempinbb8e6252012-07-31 14:30:35 +020058* Build and install into local Maven repository:
59+
Michael Ochmannb99feab2016-07-06 14:10:22 +020060----
Edwin Kempinbb8e6252012-07-31 14:30:35 +020061 mvn clean install
Michael Ochmannb99feab2016-07-06 14:10:22 +020062----
Edwin Kempinbb8e6252012-07-31 14:30:35 +020063
64
65[[publish-release]]
Yuxuan 'fishy' Wang61698b12013-12-20 12:55:51 -080066== Publish the Release
Edwin Kempinbb8e6252012-07-31 14:30:35 +020067
68* Make sure you have done the configuration needed for deployment:
69** link:dev-release-deploy-config.html#deploy-configuration-settings-xml[
70Configuration in Maven `settings.xml`]
71** Configuration in `pom.xml` for
David Pursehouse383a3182013-12-06 13:06:57 +090072link:dev-release-deploy-config.html#deploy-configuration-subprojects[subprojects]
Edwin Kempinbb8e6252012-07-31 14:30:35 +020073
Martin Fick21e278e2012-02-23 13:45:54 -070074* Deploy the new release:
Edwin Kempinbb8e6252012-07-31 14:30:35 +020075+
Michael Ochmannb99feab2016-07-06 14:10:22 +020076----
David Pursehouse652dadb2018-12-07 16:43:18 +090077 mvn deploy -DperformRelease=true
Michael Ochmannb99feab2016-07-06 14:10:22 +020078----
Edwin Kempinbb8e6252012-07-31 14:30:35 +020079
80* Push the pom change(s) to the project's repository
81`refs/for/<master|stable>`
82
83* Push the Release Tag
84+
Michael Ochmannb99feab2016-07-06 14:10:22 +020085----
Edwin Kempinbb8e6252012-07-31 14:30:35 +020086 git push gerrit-review refs/tags/v1.3:refs/tags/v1.3
Michael Ochmannb99feab2016-07-06 14:10:22 +020087----
Martin Fickec31ff42012-06-23 11:35:39 -060088
89
90GERRIT
91------
92Part of link:index.html[Gerrit Code Review]
Yuxuan 'fishy' Wang99cb68d2013-10-31 17:26:00 -070093
94SEARCHBOX
95---------