Dispatch rebottle all #69
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Dispatch rebottle all | |
on: | |
workflow_dispatch: | |
inputs: | |
extension: | |
description: Extension name | |
required: true | |
issue: | |
description: Issue number, where comment on failure would be posted | |
required: false | |
upload: | |
description: Whether to upload built bottles or not | |
required: false | |
jobs: | |
dispatch: | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: ${{github.event.inputs.formula}} | |
id: print_details | |
run: | | |
echo sender=${{github.event.sender.login}} | |
echo extension=${{github.event.inputs.extension}} | |
echo issue=${{github.event.inputs.issue}} | |
echo upload=${{github.event.inputs.upload}} | |
- name: Dispatch | |
run: | | |
json_array=() | |
extension=${{github.event.inputs.extension}} | |
for formula in ./Formula/$extension@*.rb; do | |
json="{\"formula\": \"$(basename ${formula%.*})\", \"issue\":\"${{github.event.inputs.issue}}\", \"upload\":\"${{github.event.inputs.upload}}\"}" | |
echo $json | GITHUB_TOKEN=${{ secrets.HOMEBREW_GITHUB_API_TOKEN }} gh workflow run dispatch-rebottle.yml --json | |
done |