From cd2ab8a84256eeb26e4a1e511f3bfe9e336e3b8c Mon Sep 17 00:00:00 2001 From: Carlo Cabrera <30379873+carlocab@users.noreply.github.com> Date: Wed, 31 May 2023 13:06:34 +0800 Subject: [PATCH] workflows/autopublish: remove This has been disabled for a month now, and it doesn't seem like we missed it too much. I think it's safe to remove this now. Also, now that we no longer attempt to merge approved pull requests at regular intervals, there is no need to dismiss approvals from PRs when this workflow fails. Presumably this was needed to avoid the workflow from repeatedly attempting to publish a PR that cannot be published, but this no longer a concern. --- .github/workflows/autopublish.yml | 35 -------------------- .github/workflows/publish-commit-bottles.yml | 10 +----- 2 files changed, 1 insertion(+), 44 deletions(-) delete mode 100644 .github/workflows/autopublish.yml diff --git a/.github/workflows/autopublish.yml b/.github/workflows/autopublish.yml deleted file mode 100644 index 7b24601b93a37..0000000000000 --- a/.github/workflows/autopublish.yml +++ /dev/null @@ -1,35 +0,0 @@ -name: Publish and commit bottles on schedule - -on: - workflow_dispatch: - schedule: - # Once every hour - - cron: "*/60 * * * *" - -concurrency: - group: autopublish - cancel-in-progress: true - -env: - HOMEBREW_FORCE_HOMEBREW_ON_LINUX: 1 - -permissions: - contents: read - -jobs: - autopublish: - if: github.repository == 'Homebrew/homebrew-core' - runs-on: ubuntu-22.04 - container: - image: ghcr.io/homebrew/ubuntu22.04:master - steps: - - name: Set up Homebrew - id: set-up-homebrew - uses: Homebrew/actions/setup-homebrew@master - with: - test-bot: false - - - name: Run automerge - env: - HOMEBREW_GITHUB_API_TOKEN: ${{secrets.HOMEBREW_GITHUB_PUBLIC_REPO_TOKEN}} - run: brew pr-automerge --verbose --publish diff --git a/.github/workflows/publish-commit-bottles.yml b/.github/workflows/publish-commit-bottles.yml index 63424c264b5c7..7cc308ea29271 100644 --- a/.github/workflows/publish-commit-bottles.yml +++ b/.github/workflows/publish-commit-bottles.yml @@ -331,7 +331,7 @@ jobs: working-directory: ${{steps.set-up-homebrew.outputs.repository-path}} - name: Post comment on failure - if: ${{!success()}} + if: failure() uses: Homebrew/actions/post-comment@master with: token: ${{secrets.GITHUB_TOKEN}} @@ -340,14 +340,6 @@ jobs: bot_body: ":warning: Bottle publish [failed](${{env.RUN_URL}}). CC @carlocab" bot: github-actions[bot] - - name: Dismiss approvals on failure - if: failure() - uses: Homebrew/actions/dismiss-approvals@master - with: - token: ${{secrets.GITHUB_TOKEN}} - pr: ${{inputs.pull_request}} - message: "bottle publish failed" - - name: Wait until pull request branch is in sync with local repository id: wait-until-in-sync working-directory: ${{steps.set-up-homebrew.outputs.repository-path}}