Update token usage

- Move to `GITHUB_TOKEN` where possible
- Move from `HOMEBREW_GITHUB_API_TOKEN` to
  `HOMEBREW_GITHUB_PUBLIC_REPO_TOKEN`
master
Mike McQuaid 2021-04-06 13:40:44 +01:00
parent f658174f11
commit 760281826c
7 changed files with 19 additions and 19 deletions

View File

@ -20,5 +20,5 @@ jobs:
- name: Run automerge - name: Run automerge
env: env:
HOMEBREW_GITHUB_API_TOKEN: ${{secrets.HOMEBREW_GITHUB_API_TOKEN}} HOMEBREW_GITHUB_API_TOKEN: ${{secrets.HOMEBREW_GITHUB_PUBLIC_REPO_TOKEN}}
run: brew pr-automerge --verbose --publish --autosquash run: brew pr-automerge --verbose --publish --autosquash

View File

@ -102,7 +102,7 @@ jobs:
if: ${{!success() && github.event.inputs.issue > 0}} if: ${{!success() && github.event.inputs.issue > 0}}
uses: Homebrew/actions/post-comment@master uses: Homebrew/actions/post-comment@master
with: with:
token: ${{secrets.HOMEBREW_GITHUB_API_TOKEN}} token: ${{secrets.HOMEBREW_GITHUB_PUBLIC_REPO_TOKEN}}
issue: ${{github.event.inputs.issue}} issue: ${{github.event.inputs.issue}}
body: ":x: @${{github.actor}} bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})." body: ":x: @${{github.actor}} bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})."
bot_body: ":x: Bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})." bot_body: ":x: Bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})."
@ -162,7 +162,7 @@ jobs:
- name: Push commits - name: Push commits
uses: Homebrew/actions/git-try-push@master uses: Homebrew/actions/git-try-push@master
with: with:
token: ${{secrets.HOMEBREW_GITHUB_API_TOKEN}} token: ${{secrets.HOMEBREW_GITHUB_PUBLIC_REPO_TOKEN}}
env: env:
GIT_COMMITTER_NAME: BrewTestBot GIT_COMMITTER_NAME: BrewTestBot
GIT_COMMITTER_EMAIL: 1589480+BrewTestBot@users.noreply.github.com GIT_COMMITTER_EMAIL: 1589480+BrewTestBot@users.noreply.github.com
@ -172,7 +172,7 @@ jobs:
if: ${{!success() && github.event.inputs.issue > 0}} if: ${{!success() && github.event.inputs.issue > 0}}
uses: Homebrew/actions/post-comment@master uses: Homebrew/actions/post-comment@master
with: with:
token: ${{secrets.HOMEBREW_GITHUB_API_TOKEN}} token: ${{secrets.HOMEBREW_GITHUB_PUBLIC_REPO_TOKEN}}
issue: ${{github.event.inputs.issue}} issue: ${{github.event.inputs.issue}}
body: ":x: @${{github.actor}} bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})." body: ":x: @${{github.actor}} bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})."
bot_body: ":x: Bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})." bot_body: ":x: Bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})."

View File

@ -103,7 +103,7 @@ jobs:
if: ${{!success() && github.event.inputs.issue > 0}} if: ${{!success() && github.event.inputs.issue > 0}}
uses: Homebrew/actions/post-comment@master uses: Homebrew/actions/post-comment@master
with: with:
token: ${{secrets.HOMEBREW_GITHUB_API_TOKEN}} token: ${{secrets.HOMEBREW_GITHUB_PUBLIC_REPO_TOKEN}}
issue: ${{github.event.inputs.issue}} issue: ${{github.event.inputs.issue}}
body: ":x: @${{github.actor}} bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})." body: ":x: @${{github.actor}} bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})."
bot_body: ":x: Bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})." bot_body: ":x: Bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})."
@ -163,7 +163,7 @@ jobs:
- name: Push commits - name: Push commits
uses: Homebrew/actions/git-try-push@master uses: Homebrew/actions/git-try-push@master
with: with:
token: ${{secrets.HOMEBREW_GITHUB_API_TOKEN}} token: ${{secrets.HOMEBREW_GITHUB_PUBLIC_REPO_TOKEN}}
env: env:
GIT_COMMITTER_NAME: BrewTestBot GIT_COMMITTER_NAME: BrewTestBot
GIT_COMMITTER_EMAIL: 1589480+BrewTestBot@users.noreply.github.com GIT_COMMITTER_EMAIL: 1589480+BrewTestBot@users.noreply.github.com
@ -173,7 +173,7 @@ jobs:
if: ${{!success() && github.event.inputs.issue > 0}} if: ${{!success() && github.event.inputs.issue > 0}}
uses: Homebrew/actions/post-comment@master uses: Homebrew/actions/post-comment@master
with: with:
token: ${{secrets.HOMEBREW_GITHUB_API_TOKEN}} token: ${{secrets.GITHUB_TOKEN}}
issue: ${{github.event.inputs.issue}} issue: ${{github.event.inputs.issue}}
body: ":x: @${{github.actor}} bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})." body: ":x: @${{github.actor}} bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})."
bot_body: ":x: Bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})." bot_body: ":x: Bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})."

View File

@ -86,7 +86,7 @@ jobs:
if: ${{!success() && github.event.inputs.issue > 0}} if: ${{!success() && github.event.inputs.issue > 0}}
uses: Homebrew/actions/post-comment@master uses: Homebrew/actions/post-comment@master
with: with:
token: ${{secrets.HOMEBREW_GITHUB_API_TOKEN}} token: ${{secrets.HOMEBREW_GITHUB_PUBLIC_REPO_TOKEN}}
issue: ${{github.event.inputs.issue}} issue: ${{github.event.inputs.issue}}
body: ":x: @${{github.actor}} bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})." body: ":x: @${{github.actor}} bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})."
bot_body: ":x: Bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})." bot_body: ":x: Bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})."
@ -137,7 +137,7 @@ jobs:
- name: Push commits - name: Push commits
uses: Homebrew/actions/git-try-push@master uses: Homebrew/actions/git-try-push@master
with: with:
token: ${{secrets.HOMEBREW_GITHUB_API_TOKEN}} token: ${{secrets.HOMEBREW_GITHUB_PUBLIC_REPO_TOKEN}}
env: env:
GIT_COMMITTER_NAME: BrewTestBot GIT_COMMITTER_NAME: BrewTestBot
GIT_COMMITTER_EMAIL: 1589480+BrewTestBot@users.noreply.github.com GIT_COMMITTER_EMAIL: 1589480+BrewTestBot@users.noreply.github.com
@ -147,7 +147,7 @@ jobs:
if: ${{!success() && github.event.inputs.issue > 0}} if: ${{!success() && github.event.inputs.issue > 0}}
uses: Homebrew/actions/post-comment@master uses: Homebrew/actions/post-comment@master
with: with:
token: ${{secrets.HOMEBREW_GITHUB_API_TOKEN}} token: ${{secrets.HOMEBREW_GITHUB_PUBLIC_REPO_TOKEN}}
issue: ${{github.event.inputs.issue}} issue: ${{github.event.inputs.issue}}
body: ":x: @${{github.actor}} bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})." body: ":x: @${{github.actor}} bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})."
bot_body: ":x: Bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})." bot_body: ":x: Bottle request for ${{github.event.inputs.formula}} [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})."

View File

@ -20,7 +20,7 @@ jobs:
- name: Post comment once started - name: Post comment once started
uses: Homebrew/actions/post-comment@master uses: Homebrew/actions/post-comment@master
with: with:
token: ${{secrets.HOMEBREW_GITHUB_API_TOKEN}} token: ${{secrets.HOMEBREW_GITHUB_PUBLIC_REPO_TOKEN}}
issue: ${{github.event.inputs.pull_request}} issue: ${{github.event.inputs.pull_request}}
body: ":shipit: @${{github.actor}} has [triggered a merge](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})." body: ":shipit: @${{github.actor}} has [triggered a merge](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})."
bot_body: ":robot: A scheduled task has [triggered a merge](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})." bot_body: ":robot: A scheduled task has [triggered a merge](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})."
@ -64,7 +64,7 @@ jobs:
- name: Pull bottles - name: Pull bottles
env: env:
HOMEBREW_GITHUB_API_TOKEN: ${{secrets.HOMEBREW_GITHUB_API_TOKEN}} HOMEBREW_GITHUB_API_TOKEN: ${{secrets.GITHUB_TOKEN}}
HOMEBREW_GPG_PASSPHRASE: ${{ secrets.BREWTESTBOT_GPG_SIGNING_SUBKEY_PASSPHRASE }} HOMEBREW_GPG_PASSPHRASE: ${{ secrets.BREWTESTBOT_GPG_SIGNING_SUBKEY_PASSPHRASE }}
HOMEBREW_BINTRAY_USER: brewtestbot HOMEBREW_BINTRAY_USER: brewtestbot
HOMEBREW_BINTRAY_KEY: ${{secrets.HOMEBREW_BINTRAY_KEY}} HOMEBREW_BINTRAY_KEY: ${{secrets.HOMEBREW_BINTRAY_KEY}}
@ -81,7 +81,7 @@ jobs:
- name: Push commits - name: Push commits
uses: Homebrew/actions/git-try-push@master uses: Homebrew/actions/git-try-push@master
with: with:
token: ${{secrets.HOMEBREW_GITHUB_API_TOKEN}} token: ${{secrets.GITHUB_TOKEN}}
env: env:
GIT_COMMITTER_NAME: BrewTestBot GIT_COMMITTER_NAME: BrewTestBot
GIT_COMMITTER_EMAIL: 1589480+BrewTestBot@users.noreply.github.com GIT_COMMITTER_EMAIL: 1589480+BrewTestBot@users.noreply.github.com
@ -91,7 +91,7 @@ jobs:
if: ${{!success()}} if: ${{!success()}}
uses: Homebrew/actions/post-comment@master uses: Homebrew/actions/post-comment@master
with: with:
token: ${{secrets.HOMEBREW_GITHUB_API_TOKEN}} token: ${{secrets.HOMEBREW_GITHUB_PUBLIC_REPO_TOKEN}}
issue: ${{github.event.inputs.pull_request}} issue: ${{github.event.inputs.pull_request}}
body: ":warning: @${{github.actor}} bottle publish [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})." body: ":warning: @${{github.actor}} bottle publish [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})."
bot_body: ":warning: Bottle publish [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})." bot_body: ":warning: Bottle publish [failed](${{github.event.repository.html_url}}/actions/runs/${{github.run_id}})."
@ -101,7 +101,7 @@ jobs:
if: ${{!success()}} if: ${{!success()}}
uses: Homebrew/actions/dismiss-approvals@master uses: Homebrew/actions/dismiss-approvals@master
with: with:
token: ${{secrets.HOMEBREW_GITHUB_API_TOKEN}} token: ${{secrets.HOMEBREW_GITHUB_PUBLIC_REPO_TOKEN}}
pr: ${{github.event.inputs.pull_request}} pr: ${{github.event.inputs.pull_request}}
message: "bottle publish failed" message: "bottle publish failed"

View File

@ -37,7 +37,7 @@ jobs:
if: ${{ steps.remove_disabled.outputs.formulae-removed == 'true' }} if: ${{ steps.remove_disabled.outputs.formulae-removed == 'true' }}
uses: peter-evans/create-pull-request@45c510e1f68ba052e3cd911f661a799cfb9ba3a3 uses: peter-evans/create-pull-request@45c510e1f68ba052e3cd911f661a799cfb9ba3a3
with: with:
token: ${{ secrets.HOMEBREW_GITHUB_API_TOKEN }} token: ${{ secrets.HOMEBREW_GITHUB_PUBLIC_REPO_TOKEN }}
branch: remove-disabled-formulae branch: remove-disabled-formulae
title: Remove disabled formulae title: Remove disabled formulae
body: > body: >

View File

@ -9,17 +9,17 @@ jobs:
- name: Check commit format - name: Check commit format
uses: Homebrew/actions/check-commit-format@master uses: Homebrew/actions/check-commit-format@master
with: with:
token: ${{secrets.HOMEBREW_GITHUB_API_TOKEN}} token: ${{secrets.HOMEBREW_GITHUB_PUBLIC_REPO_TOKEN}}
- name: Cancel previous runs - name: Cancel previous runs
uses: Homebrew/actions/cancel-previous-runs@master uses: Homebrew/actions/cancel-previous-runs@master
if: always() if: always()
with: with:
token: ${{secrets.HOMEBREW_GITHUB_API_TOKEN}} token: ${{secrets.HOMEBREW_GITHUB_PUBLIC_REPO_TOKEN}}
- name: Label pull request - name: Label pull request
uses: Homebrew/actions/label-pull-requests@master uses: Homebrew/actions/label-pull-requests@master
if: always() if: always()
with: with:
token: ${{secrets.HOMEBREW_GITHUB_API_TOKEN}} token: ${{secrets.HOMEBREW_GITHUB_PUBLIC_REPO_TOKEN}}
def: | def: |
[ [
{ {