Skip to content
Snippets Groups Projects

CiviCRM v5.x.0: Publish a stable release

Prerequisites

See Prerequisites

1: Set the final version to 5.X.0

cd ~/src/master
git checkout 5.X
git pull --ff-only origin 5.X
./tools/bin/scripts/set-version.php 5.X.0 --commit
git push origin 5.X

2: Sanity checks

3: Prepare and identify the final tarballs

After running, determine the identity of the final build:

gsutil ls gs://civicrm-build/5.2/*json

For example, we might pick gs://civicrm-build/5.2/civicrm-5.2.0-201705030600.json.

4: Publish

For a typical release, you can run the full process in one command:

cd ~/src/master
releaser -v gs://civicrm-build/5.2/civicrm-5.2.0-201705030600.json get sign tag publish

If this branch will have future ESR support, then you should also publish releases to lab.c.o/esr/*.

releaser -v gs://civicrm-build/5.2/civicrm-5.2.0-201705030600.json get sign tag publish esr-tag esr-publish

TIP: releaser can run steps individually, and it can provide a preview of actions it would take (--dry-run aka -N).

To ensure the various tags were published and match the branches, use civi-git-table, as in:

civi-git-table --fetch 5.2.0 5.2

5: Mirror the branch (ESR)

If this branch will have future ESR support, then you should setup mirror branches for esr and security.

givi branch -A 5.X-esr origin/5.X
givi push -A -u esr 5.X-esr

givi branch -A 5.X-security origin/5.X
givi push -A -u security 5.X-security

6: Update versions.json

Services such as the civicrm.org download page and the in-app version check depend on a file named versions.json. Update this.

## Find and examine the current list of branches.
pushd /var/www/latest.civicrm.org/public/
ls -la versions.json
./bin/pb branch:list

## Add the new branch. Be sure to adjust versions.
./bin/pb branch:status 5.2 stable

## Add the new release. Be sure to adjust versions/dates.
./bin/pb release:add 5.2.0 --date=2018-05-03 --security=false

## If appropriate, set the deprecation and eol dates for the previous
## version.
./bin/pb branch:status 5.1 -D 2018-06-10 -E 2018-06-15

Preview the upgrade messages that will be displayed on various versions. This example previews the perspective from 5.0.2 and 5.8.0 (adjust to taste):

http://latest.civicrm.org/stable.php?format=devPreview&versions=5.0.2,5.8.0

Finally:

## Make the change persistent.
git commit versions.json
git push origin master

## Go back
popd

7: Make new versions visible on download sites

If there is a change in ESR status, then:

Log into https://civicrm.org/user and clear the page-cache in https://civicrm.org/admin/config/development/performance

Browse https://sourceforge.net/projects/civicrm/files/civicrm-stable - confirm that:

  • The new upload is present.
  • The new civicrm-X.Y.Z-drupal.tar.gz is the default download.

Note that it may take some time to reflect default download on sf.net.