Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 22 additions & 16 deletions .github/workflows/update-builder-toml.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v6
with:
fetch-depth: 0

- name: Get Builders
id: get-builders
Expand All @@ -28,7 +30,7 @@ jobs:
if [ -f ${{ env.BUILDERS_FILEPATH }} ]; then
builders=$(jq -c '.builders' ${{ env.BUILDERS_FILEPATH }})
else
# Strip off the Github org prefix from repo name
# Strip off the GitHub org prefix from repo name
# paketo-buildpacks/builder-with-some-name --> builder-with-some-name
registry_repo=$(echo "${{ github.repository }}" | sed 's/^.*\///')
builders=$(jq -n -c '[
Expand All @@ -51,11 +53,27 @@ jobs:
echo "builders=$builders"
echo "builders=$builders" >> "$GITHUB_OUTPUT"

- name: Checkout branch
uses: paketo-buildpacks/github-config/actions/pull-request/checkout-branch@main
with:
branch: "automation/builder-toml-update"

- name: Rebase branch
uses: paketo-buildpacks/github-config/actions/pull-request/rebase-branch@main
with:
keyid: ${{ secrets.PAKETO_BOT_GPG_SIGNING_KEY_ID }}
key: ${{ secrets.PAKETO_BOT_GPG_SIGNING_KEY }}
fail_on_rebase_failure: true

- name: Git push
uses: paketo-buildpacks/github-config/actions/pull-request/push-branch@main
with:
branch: "automation/builder-toml-update"
force: true

update:
name: Update builder.toml
runs-on: ubuntu-24.04
outputs:
commit_sha: ${{ steps.commit.outputs.commit_sha }}
needs: preparation
strategy:
max-parallel: 1
Expand All @@ -65,20 +83,13 @@ jobs:
steps:
- name: Check out
uses: actions/checkout@v6
with:
fetch-depth: 0


- name: Checkout branch
uses: paketo-buildpacks/github-config/actions/pull-request/checkout-branch@main
with:
branch: "automation/builder-toml-update"

- name: Rebase branch
uses: paketo-buildpacks/github-config/actions/pull-request/rebase-branch@main
with:
keyid: ${{ secrets.PAKETO_BOT_GPG_SIGNING_KEY_ID }}
key: ${{ secrets.PAKETO_BOT_GPG_SIGNING_KEY }}

- name: Update builder.toml
uses: paketo-buildpacks/github-config/actions/builder/update@main
with:
Expand All @@ -100,15 +111,10 @@ jobs:
with:
branch: "automation/builder-toml-update"

- name: Output commit sha
if: ${{ steps.commit.outputs.commit_sha != '' }}
run: echo "commit_sha=${{ steps.commit.outputs.commit_sha }}" >> "$GITHUB_OUTPUT"

open-pull-request:
name: Open pull request
runs-on: ubuntu-24.04
needs: update
if: ${{ needs.update.outputs.commit_sha != '' }}
steps:
- name: Check out
uses: actions/checkout@v6
Expand Down
2 changes: 1 addition & 1 deletion scripts/.util/tools.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"crane": "v0.21.3",
"crane": "v0.21.4",
"pack": "v0.40.2"
}
Loading