hc99's picture
Add files using upload-large-folder tool
26e6f31 verified
name: Build and publish latest changelog
# see ./.github/workflows/build_changelog.yml for docs
on:
workflow_call:
env:
TEMP_BRANCH_PREFIX: "ci-changelog"
PULL_REQUEST_TITLE: "chore(ci): changelog rebuild"
FILES_TO_COMMIT: "CHANGELOG.md"
permissions:
contents: read
jobs:
publish_changelog:
if: github.repository == 'aws-powertools/powertools-lambda-python'
# Force Github action to run only a single job at a time (based on the group name)
# This is to prevent race-condition and inconsistencies with changelog push
concurrency:
group: changelog-build
runs-on: ubuntu-latest
permissions:
contents: write # create temporary branch with changelog
pull-requests: write # create PR
steps:
- name: Checkout repository # reusable workflows start clean, so we need to checkout again
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
fetch-depth: 0
- name: "Generate latest changelog"
run: make changelog
- name: Create PR
id: create-pr
uses: ./.github/actions/create-pr
with:
files: ${{ env.FILES_TO_COMMIT }}
temp_branch_prefix: ${{ env.TEMP_BRANCH_PREFIX }}
pull_request_title: ${{ env.PULL_REQUEST_TITLE }}
github_token: ${{ secrets.GITHUB_TOKEN }}