CI: add autobump workflow (#145518)

This commit is contained in:
Sean Molenaar 2023-04-21 18:23:37 +02:00 committed by GitHub
parent f50ff6c3e3
commit cae760dfdf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 40 additions and 0 deletions

40
.github/workflows/autobump.yml vendored Normal file
View File

@ -0,0 +1,40 @@
name: Bump casks on schedule or request
on:
workflow_dispatch:
inputs:
casks:
description: Custom list of casks to livecheck and bump if outdated
required: false
schedule:
# Every day at 5am
- cron: "0 5 * * *"
env:
CASKS: >
google-chrome
firefox
permissions:
contents: read
jobs:
autobump:
if: github.repository == 'Homebrew/homebrew-cask'
runs-on: macos-latest
steps:
- name: Set up Homebrew
id: set-up-homebrew
uses: Homebrew/actions/setup-homebrew@master
- name: Configure Git user
uses: Homebrew/actions/git-user-config@master
with:
username: ${{ (github.event_name == 'workflow_dispatch' && github.actor) || 'BrewTestBot' }}
- name: Bump casks
uses: Homebrew/actions/bump-packages@master
continue-on-error: true
with:
token: ${{ secrets.HOMEBREW_CASKS_REPO_WORKFLOW_TOKEN }}
casks: ${{ github.event.inputs.casks || env.CASKS }}