Skip to content

Commit

Permalink
Merge pull request #36 from braingram/add_changelog
Browse files Browse the repository at this point in the history
add changelog and workflow to test for entries
  • Loading branch information
braingram authored Oct 18, 2023
2 parents 4b33502 + 1427277 commit 7eafe9e
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 0 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/changelog.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Changelog

on:
pull_request:
types: [labeled, unlabeled, opened, synchronize, reopened]

# Only cancel in-progress jobs or runs for the current workflow
# This cancels the already triggered workflows for a specific PR without canceling
# other instances of this workflow (other PRs, scheduled triggers, etc) when something
# within that PR re-triggers this CI
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
changelog:
name: Confirm changelog entry
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Grep for PR number in CHANGES.rst
run: grep -P '\[[^\]]*#${{github.event.number}}[,\]]' CHANGES.rst
if: ${{ !contains(github.event.pull_request.labels.*.name, 'no-changelog-entry-needed') }}
4 changes: 4 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
0.0.4 (unreleased)
------------------

- added changelog [#36]

0 comments on commit 7eafe9e

Please sign in to comment.