Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

workflows/pkg-installer: create an issue when publish fails #18389

Merged
merged 1 commit into from
Sep 24, 2024
Merged
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
26 changes: 26 additions & 0 deletions .github/workflows/pkg-installer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -213,3 +213,29 @@ jobs:
run: gh release upload --repo Homebrew/brew
"${GITHUB_REF//refs\/tags\//}"
"${{ needs.build.outputs.installer_path }}"

issue:
needs: [build, test, upload]
if: always() && github.event_name == 'release'
runs-on: ubuntu-latest
env:
RUN_URL: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
permissions:
# To create or update issues
issues: write
steps:
- name: Open, update, or close pkg installer issue
uses: Homebrew/actions/create-or-update-issue@master
with:
title: Failed to publish pkg installer
body: >
The pkg installer workflow [failed](${{ env.RUN_URL }}) for release
${{ github.ref_name }}. No pkg installer was uploaded to the GitHub
release.
labels: bug,release blocker
update-existing: ${{ contains(needs.*.result, 'failure') }}
close-existing: ${{ needs.upload.result == 'success' }}
close-from-author: github-actions[bot]
close-comment: >
The pkg installer workflow [succeeded](${{ env.RUN_URL }}) for
release ${{ github.ref_name }}. Closing this issue.
Loading