HowTo: Release iHRIS Software 4.0

From IHRIS Wiki

Creating a New Release

The tool to handle releasing is I2CE/tools/release.php. The release.php script has two functions -- to bump the version numbers of any modules that have changed since the last release, and to create tarballs of the various software components.

Prerequisites

Please run <source lang='bash'> sudo apt-get install pcregrep </source>

Bazaar Branches and Subdirectories

The release.php script operates on the bazaar branches that contain your code. It assumes that every subdirectory from which release.php is being run is a potential bazaar branch to perform a release on. It will cycle through each of the bazaar branches/subdirectories and warn about any uncommitted changes.

The top-level module is the module at the root of the bazaar branch. If release.php cannot find a module at the root of a bazaar branch, then that branch/sub-directory is ignored.

Versioning

Versioning is based on a three part versioning system, XXX.YYY.ZZZ. The XXXX is "major" part, YYYY is the "sub-major part" and ZZZ is the "minor" part. For example version 4.0.12 has a major version number of 4, a sub-major version number of 0 and a minor version number of 12. Anything that follows the ZZZZ is ignored for the purposes of releasing.

Tagging

The release.php script tags each of the bazaar branches to indicate which revision number was used for the release. The tag follows the form "XXX.YYY.ZZZ-release" so you might see a "4.0.12-release" as a tag on that revision.

Version Bumping

If there has not been yet been a release of a branch (detected through the release tag), the release version will the release version of the top-level module.

If however, there already has been a release, then the release.php script will ask you if you want to increase the version number of a module in either of these scenarios:

  • Top-Level Module: The top-level module can be version bumped if the the XXX.YYY.ZZZ part of he current version of the top-level module is less than or equal to the version number of the most recent release tag.
  • Sub-Modules: Any sub-module can be bumped if it has had changes to its files since the last release and has the same major and sub-major version numbers as the top-level module/

If a module is going to be version bumped, it will be bumped to the version that it is going to be released on.

Release Branches

Tarballs

Tarballs are created for each of the bazaar branches which include all the files except any packaging or bazaar files.

Translations

By default, the release tarballs include the translations for the following locales: fr, pt, pt_BR,sw, et, it. If you wish to modify this list, you can do so using ---locales=XX,YY,ZZ

Debian Packaging

The tool to handle packaging is I2CE/tools/debian.php and is designed to function for several packaging scenarios. You do not need to make a release in order to make debian packages

First Step:Adding a PGP Key To Launchpad

Debian Packaging Scenario: Release

Debian Packaging Scenario: Updating Translations for a Release

Debian Packaging Scenario: Testing/Release Candidate