Skip to content

Creating a New Release

Wilfred Tyler Gee edited this page Jul 27, 2020 · 5 revisions

Note: This should be done with the panoptes repo as the origin, not from a fork and should be done locally, not on Github.

  1. Make sure all relevant branches are merged into develop.
    1. git fetch origin
  2. Create a release branch. The vX.Y.Z should (usually) be the next minor bump, i.e. the Z.
    1. git checkout -b release-vX.Y.Z origin/develop
    2. Update the CHANGELOG as necessary and commit to branch.
  3. Merge with master:
    1. git checkout master
    2. git merge --no-ff release-vX.Y.Z
    3. Resolve any conflicts and commit.
  4. Test distribution:
    1. python setup.py sdist bdist_wheel
    2. Test PyPi upload (NB: you will need credentials):
      1. python -m twine check dist/*
    3. Assuming no problems, remove dist so it's clean:
      1. rm -rf dist/
  5. Tag and push current release to master:
    1. git tag vX.Y.Z
    2. git push --tags origin master
  6. Create a dist release and push to PyPi (NB: you will need credentials):
    1. python setup.py sdist bdist_wheel
    2. Upload to PyPi via twine:
      1. python -m twine check dist/*
      2. python -m twine upload dist/*
  7. Merge with develop:
    1. git checkout develop
    2. git merge --no-ff release-vX.Y.Z
    3. Tag next release in dev state:
      1. e.g., if vX.Y.Z is v0.2.5 then here you would use v0.2.6dev
      2. git tag vX.Y.Zdev
    4. git push --tags origin develop
  8. Remove release branch:
    1. git branch -D release-vX.Y.Z
  9. Create a release on GitHub (TODO - automate github release).

Note: Docker images are built automatically in the GCP environment upon push to master and develop.