Skip to content

Commit

Permalink
docs: add PR environment variable
Browse files Browse the repository at this point in the history
  • Loading branch information
addetz committed Oct 23, 2024
1 parent 092813c commit b4e43a8
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions .github/workflows/clean-up-unused-images.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,12 @@ jobs:
- name: Create PR with unused images
run: |
unused_image_count=$(wc -l < unused_images.json)
if unused_image_count == 0; then
"No images found to remove."
exit 0
fi
# Ensure that we are on master.
git checkout master
Expand Down Expand Up @@ -87,9 +93,11 @@ jobs:
The images are identified using `scripts/find-unused-images.sh` script.
Please review this PR carefully before merging it.'
gh pr create --base master --title "docs: clean up librarium unused images " --body "$pr_body" --label "$backport_labels"
pr_id=$(gh pr create --base master --title "docs: clean up librarium unused images " --body "$pr_body" --label "$backport_labels")
echo "CREATED_CLEANUP_PR=pr_id" >> $GITHUB_ENV
echo "PR successfully created $CREATED_CLEANUP_PR."
env:
GH_TOKEN: ${{ steps.import-secrets.outputs.VAULT_GITHUB_TOKEN }}


0 comments on commit b4e43a8

Please sign in to comment.