Release workflow¶
Versioneer (optional)¶
Upgrade versioneer if a new version is available.
Check the upgrade notes if additional steps are required
Upgrade versioneer
pip3 install --upgrade versioneer
Remove the old versioneer.py file
rm versioneer.py
Install new versioneer.py file
python3 -m versioneer install --vendor
Revert the changes in
src/maicos/__init__.py
Commit changes
Create release¶
Prepare a Release Pull Request
Based on the main branch create branch
release-x.y.z
and a PR.Ensure that all CI tests pass.
Optionally, run the tests locally to double-check.
Update the Changelog
Edit the changelog located in
CHANGELOG
and add the new version and the date of the release.Merge the PR and Create a Tag
Merge the release PR.
Update the
main
branch and check that the latest commit is the release PR withgit log
Create a tag on directly the
main
branch.Push the tag to GitHub. For example for a release of version
x.y.z
:git checkout main git pull git tag -a vx.y.z -m "Release vx.y.z" git push --tags
Trigger release workflow
Once the tag is pushed, navigate to the Actions tab of the repository.
Select the
Build
workflow section.Click on the “Run workflow” dropdown and select the
vx.y.z
tag you just created.
Finalize the GitHub Release
- The CI will automatically:
Publish the package to PyPI.
Create a draft release on GitHub.
Update the GitHub release notes by pasting the changelog for the version.
Merge Conda Recipe Changes
May resolve and then merge an automatically created PR on the conda recipe.
Once thus PR is merged and the new version will be published automatically on the conda-forge channel.
After the release¶
Add a placeholder section titled Unreleased for future updates.