Skip to content

MAINT: Automate renaming of towncrier stubs #30

MAINT: Automate renaming of towncrier stubs

MAINT: Automate renaming of towncrier stubs #30

Workflow file for this run

name: Changelog
on: # yamllint disable-line rule:truthy
pull_request:
types: [opened, synchronize, labeled, unlabeled]
# https://joht.github.io/johtizen/build/2022/01/20/github-actions-push-into-repository.html#git-commit-within-a-pull-request#example-4
jobs:
changelog_checker:
name: Check towncrier entry in doc/changes/devel/
runs-on: ubuntu-latest
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
BOT_USERNAME: changelog-bot
GIT_COMMITTER_NAME: "MNE CI Bot"
GIT_COMMITTER_EMAIL: "[email protected]"
defaults:
run:
shell: bash -el {0}
permissions:
contents: write
steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.head_ref }}
- run: actions/setup-python@v5
- run: |
pip install --upgrade towncrier pygithub
python ./.github/actions/rename_towncrier/rename_towncrier.py
- uses: stefanzweifel/git-auto-commit-action@v5
id: commit-action
- run: exit 1
if: steps.commit-action.outputs.changes_detected == 'false'
# - uses: larsoner/action-towncrier-changelog@co # revert to scientific-python @ 0.1.1 once bug is fixed