Update CHANGELOG Checks to use new community check #60675
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CHANGELOG Checks | |
on: | |
pull_request_target: | |
paths: | |
- CHANGELOG.md | |
permissions: | |
contents: read | |
pull-requests: write | |
## NOTE: !!! | |
## When changing these workflows, ensure that the following is updated: | |
## - Documentation: docs/continuous-integration.md | |
## - Documentation: docs/makefile-cheat-sheet.md | |
## - Makefile: ./GNUmakefile | |
jobs: | |
comment: | |
name: Comment on Non-Maintainer Edit | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Community Check | |
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7 | |
with: | |
sparse-checkout: .github/actions/community_check | |
- name: Run Community Check | |
id: community_check | |
uses: ./.github/actions/community_check | |
with: | |
user_login: ${{ github.event.pull_request.user.login }} | |
maintainers: ${{ secrets.MAINTAINERS }} | |
- name: Check for Existing Comment | |
id: prc | |
if: steps.community_check.outputs.maintainer == 'false' | |
uses: peter-evans/find-comment@3eae4d37986fb5a8592848f6a574fdf654e61f9e # v3.1.0 | |
with: | |
issue-number: ${{ github.event.pull_request.number }} | |
comment-author: "github-actions[bot]" | |
body-includes: "Please note that the `CHANGELOG.md` file contents are handled by the maintainers during merge" | |
- name: Leave a New Comment | |
if: steps.prc.outputs.comment-id == '' | |
uses: peter-evans/create-or-update-comment@71345be0265236311c031f5c7866368bd1eff043 # v4.0.0 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
issue-number: ${{ github.event.pull_request.number }} | |
body: |- | |
Thank you for your contribution! :rocket: | |
Please note that the `CHANGELOG.md` file contents are handled by the maintainers during merge. This is to prevent pull request merge conflicts, especially for contributions which may not be merged immediately. Please see the [Contributing Guide](https://github.com/hashicorp/terraform-provider-aws/blob/main/docs/contributing) for additional pull request review items. | |
Remove any changes to the `CHANGELOG.md` file and commit them in this pull request to prevent delays with reviewing and potentially merging this pull request. |