Update shared github-config #22434
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: Update shared github-config | |
on: | |
schedule: | |
- cron: '30 1 * * *' | |
workflow_dispatch: {} | |
jobs: | |
build: | |
name: Create PR to update shared files | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
token: ${{ secrets.PAKETO_BOT_GITHUB_TOKEN }} | |
- name: Checkout github-config | |
uses: actions/checkout@v3 | |
with: | |
repository: paketo-buildpacks/github-config | |
path: github-config | |
- name: Checkout Branch | |
uses: paketo-buildpacks/github-config/actions/pull-request/checkout-branch@main | |
with: | |
branch: automation/github-config/update | |
- name: Run the sync action for template CNB | |
uses: paketo-buildpacks/github-config/actions/sync@main | |
with: | |
workspace: /github/workspace/template-cnb | |
config: /github/workspace/github-config/implementation | |
- name: Cleanup | |
run: rm -rf github-config | |
- name: Commit | |
id: commit | |
uses: paketo-buildpacks/github-config/actions/pull-request/create-commit@main | |
with: | |
message: "Updating github-config" | |
pathspec: "." | |
keyid: ${{ secrets.PAKETO_BOT_GPG_SIGNING_KEY_ID }} | |
key: ${{ secrets.PAKETO_BOT_GPG_SIGNING_KEY }} | |
- name: Push Branch | |
if: ${{ steps.commit.outputs.commit_sha != '' }} | |
uses: paketo-buildpacks/github-config/actions/pull-request/push-branch@main | |
with: | |
branch: automation/github-config/update | |
- name: Open Pull Request | |
if: ${{ steps.commit.outputs.commit_sha != '' }} | |
uses: paketo-buildpacks/github-config/actions/pull-request/open@main | |
with: | |
token: ${{ secrets.PAKETO_BOT_GITHUB_TOKEN }} | |
title: "Updates github-config" | |
branch: automation/github-config/update |