Release process for projects using buildsystem

We perform all releases from git simply by pushing a release/<version number> tag

Before creating the tag you should do some basic checks

check the COMPONENT_VERSION in the root Makefile matches the version number you are releasing, if not change it and commit it so it does.

Any files that should not be put in the distribution archive must be placed in the .gitattributes file, as a minimum it should contain attributes for the .gitignore and gitattributes files e.g.

.gitignore export-ignore
.gitattributes export-ignore

in your clone do

git branch -vv

ensure the top commit looks right and is what you want to tag, for extra paranoia check the .git/config to ensure the origin is the correct server. You do not have to tag from master, for example if this is a maintenance release of an old edition and you are tagging from a branch etc. just ensure you are where you want the release to be.

Create the tag with

git tag -s -m 'Official Release' release/<version number>

Ensure the version number in the tag matches the component version.

Now run

make dist

if you get

Makefile:45: \*\*\* Component Version "1.0" and GIT tag version "1.1" do not match. Stop.

you did not get the tag and version numbers lined up, go back, remove your local tag with

git tag -d release/<bad version>

and try again

when you get a buildsystem-1.0.tar.gz (with appropriate version number) well done

Check the contents of the tar are what you intended to release and adjust if not (obviously you will need to remove your local tag and start over with fresh commits.

Next do a dry run push

git push -n --tags

ensure this shown the correct repo and the release tag something like

[gitano] Welcome to the NetSurf Gitano instance.
Counting objects: 1, done.
Writing objects: 100% (1/1), 800 bytes | 0 bytes/s, done.
Total 1 (delta 0), reused 0 (delta 0)
To ssh://
 * [new tag]         release/1.3.1-3 -> release/1.3.1-3

If that verifies as correct

git push --tags
git push

and the release tag is pushed, too late now so be careful and check!