-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Labels
featureProduct featureProduct feature
Description
Rationale:
- More descriptive
- Enabling the user to understand the content, scope and impact of the release
- Enabling the user to decide about importance and risks for updating to this release
- see
- Team Guidelines "Changelog Draft"
- and project-keeper software design document
Concept:
- User writes code name to change log
- GitHub workflow picks up this code name and appends it to the version number
Comparison:
- Before: "1.2.3", as for python-toolbox
- After: "1.2.3 Dependency Upgrade", as for project-keeper
Special cases
- Repository pytest-plugins is a multi-project repository
- Each with its own changes files
- Still, GitHub releases are for the whole repo
- Git tags are prefixed by the name of each of the subprojects to ensure unique names
- Changes File does not contain any Code name:
- Fallback: just use version number
Implementation Options
- Simple shell commands
- Nox Task
release:title
Option Nox Task
- Is more robust and flexible
- Can handle errors, e.g. no changes file, or no code name
- Changes file is required by current workflows anyway
- This requires to pass the version number to the nox task
- Again: special case for multi-project repository pytest-plugins
- The version number is not unique when looking at multiple subprojects.
- Instead each Git Tag is prefixed by the name of the resp. subproject.
- Hence besides the changes file (or its version suffix) we need to pass the git tag.
Option: Simple Shell Commands
TITLE=${GITHUB_REF_NAME}
CHANGES_FILE=./doc/changes/changes_${GITHUB_REF_NAME}.md
if CODE_NAME=$(grep "Code name: " "$CHANGES_FILE"); then
TITLE="${TITLE} $(echo ${CODE_NAME} | cut -c 12-)"
fi
Option: Nox Task Writes to a Shell Variable
GitHub Workflow Implementation
- name: GitHub Release
run: >
TITLE=$(poetry run -- nox -s release:title -- --prefix TAG CHANGES_FILE)
gh --title "$TITLE"
Option: Nox Task in Separate GitHub Workflow Step
GitHub Workflow Implementation
- name: Get Release Title
id: release-title
run: poetry run -- nox -s release:title -- --prefix TAG CHANGES_FILE >> $GITHUB_OUTPUT
- name: GitHub Release
run: gh --title ${{ steps.release-title.outputs.release-title }}
Metadata
Metadata
Assignees
Labels
featureProduct featureProduct feature