Skip to content

Release Procedure

Joris Roovers edited this page Mar 7, 2023 · 18 revisions

Pre-release work

  • Check that you've included the latest CLI output in the documentation homepage
  • Update the CHANGELOG.md
  • Consider releasing a release candidate first (e.g. 0.19.0.rc1)

Release

Set env var, used below

export GITLINT_VERSION="v0.19.0rc1"

Commit and push release commit to github

Template commit message:

0.1.0 release

[copy release notes here]

Full Release details in CHANGELOG.md.

WAIT FOR CI TO FINISH TESTING

Tag git commit

git tag $GITLINT_VERSION
git tag --list
git push --tags

Create a new release on github

Go to the releases page and create a new release. Copy in changes from the raw CHANGELOG.md

Publishing a github release will automatically trigger the gitlint release automation: https://github.com/jorisroovers/gitlint/actions/workflows/github-release.yml

Note that making an edit to a published release will NOT retrigger the release automation (so it's safe to edit typos the release notes).

WAIT FOR THE RELEASE AUTOMATION TO FINISH

Push new docs

hatch run docs:mkdocs gh-deploy

Manual sanity checks

PyPI

virtualenv "/tmp/gitlint-release-$GITLINT_VERSION" &&  source "/tmp/gitlint-release-$GITLINT_VERSION/bin/activate"
pip install gitlint
gitlint --version
gitlint --debug

Docker

# Remove local copies
docker image rm -f jorisroovers/gitlint:$GITLINT_VERSION
docker image rm -f jorisroovers/gitlint:latest
docker image rm -f jorisroovers/gitlint


# Pull image from dockerhub and test again
docker run -v $(pwd):/repo jorisroovers/gitlint:$GITLINT_VERSION --version
docker run -v $(pwd):/repo jorisroovers/gitlint:$GITLINT_VERSION --debug
docker run -v $(pwd):/repo jorisroovers/gitlint:latest --version
docker run -v $(pwd):/repo jorisroovers/gitlint:latest --debug
docker run -v $(pwd):/repo jorisroovers/gitlint --version
docker run -v $(pwd):/repo jorisroovers/gitlint --debug

Post Release Steps

1. Bump version to dev

Bump the version number in gitlint/__init__.py

# From host system
export NEW_VERSION="0.9.0dev"
echo -e "Version bump to $NEW_VERSION\n\nBumped version to $NEW_VERSION." > /tmp/gitlint-$NEW_VERSION-version-bump-commitmsg
git commit -F /tmp/gitlint-$NEW_VERSION-version-bump-commitmsg
git tag $NEW_VERSION
git tag --list
git show # Tag should show up
git push

Make sure to shutdown any AWS Windows testing VMs

Ask harens in associated Release Plan issue to push builds for homebrew and macports

Close the release github milestone and Release Plan issue

Create Release Plan issue and milestone for next release on github

Announce new release (social media, etc)

Clone this wiki locally