Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add release drafter github action #1416

Merged
merged 22 commits into from Jun 20, 2021
Merged
Show file tree
Hide file tree
Changes from 13 commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
51 changes: 51 additions & 0 deletions .github/release-drafter.yml
@@ -0,0 +1,51 @@
name-template: "$RESOLVED_VERSION"
tag-template: "$RESOLVED_VERSION"

categories:
- title: "Backwards Incompatible Changes"
labels:
- "backwards incompatible"

- title: "Features"
labels:
- "feature"
- "enhancement"
# usually combined with enhancement (avoid double listing)
- "deprecation"

- title: "Bug Fixes"
labels:
- "bug"
- "bug fix"

- title: "Other Changes"
labels:
- "dependency"
- "docs"
- "trivial"
- "maintenance"

change-template: "- $TITLE (#$NUMBER) @$AUTHOR"
ssbarnea marked this conversation as resolved.
Show resolved Hide resolved
ssbarnea marked this conversation as resolved.
Show resolved Hide resolved
exclude-labels:
- "skip-changelog"
template: |
$CHANGES

version-resolver:
major:
labels:
- "backwards incompatible"
minor:
labels:
- "feature"
- "enhancement"
- "deprecation"
patch:
labels:
- "bug fix"
- "bug"
- "dependency"
- "docs"
- "maintenance"
ssbarnea marked this conversation as resolved.
Show resolved Hide resolved
- "trivial"
ssbarnea marked this conversation as resolved.
Show resolved Hide resolved
default: minor
18 changes: 18 additions & 0 deletions .github/workflows/release-drafter.yml
@@ -0,0 +1,18 @@
name: release-drafter

on:
push:
# branches to consider in the event; optional, defaults to all
branches:
- master
- "releases/**"
- "stable/**"

jobs:
update_release_draft:
runs-on: ubuntu-20.04
ssbarnea marked this conversation as resolved.
Show resolved Hide resolved
steps:
# Drafts your next release notes as Pull Requests are merged into "master"
- uses: release-drafter/release-drafter@v5
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
5 changes: 1 addition & 4 deletions CONTRIBUTING.md
Expand Up @@ -28,17 +28,14 @@ To help keeping track of the releases and their changes, here's the current rele

- Check to see if any recently merged PRs are missing from the milestone of the version about to be released.
- Create a branch for the release. _Ex: release-3.4.0_.
- Update the [CHANGELOG](CHANGELOG.md) with the version, date and using the one-line descriptions
from the PRs included in the milestone of the version.
Check the previous release changelog format for an example. Don't forget the "Thanks @contributor" mentions.
- Update the [CHANGELOG](CHANGELOG.md) with the version, date and add the text from [drafter release](https://github.com/jazzband/pip-tools/releases).
- Push the branch to your fork and create a pull request.
- Merge the pull request after the changes being approved.
- Make sure that the tests/CI still pass.
- Once ready, go to `Github pip-tools Homepage > releases tab > Draft a new release` and type in:
- _Tag version:_ The exact version number, following [Semantic Versioning](https://blog.versioneye.com/2014/01/16/semantic-versioning/). _Ex: 3.4.0_
- _Target:_ master. As a general rule, the HEAD commit of the master branch should be the release target.
- _Release title:_ Same as the tag. _Ex: 3.4.0_
- _Describe this release:_ Copy of this release's changelog segment.
- Publish release. This will push a tag on the HEAD of master, trigger the CI pipeline and
deploy a pip-tools release in the **Jazzband private package index** upon success.
- The pip-tools "lead" project members will receive an email notification to review the release and
Expand Down