Skip to content

1.33.0

1.33.0 #157

Workflow file for this run

name: brew test-bot
on:
pull_request:
jobs:
check-generate:
runs-on: macOS-latest
outputs:
matrix: ${{ steps.generate-matrix.outputs.matrix }}
steps:
- name: Set up Homebrew
id: set-up-homebrew
uses: Homebrew/actions/setup-homebrew@master
with:
core: true
- name: Cache Homebrew Bundler RubyGems
id: cache
uses: actions/cache@v4
with:
path: ${{ steps.set-up-homebrew.outputs.gems-path }}
key: ${{ runner.os }}-rubygems-${{ steps.set-up-homebrew.outputs.gems-hash }}
restore-keys: ${{ runner.os }}-rubygems-
- name: Install Homebrew Bundler RubyGems
if: steps.cache.outputs.cache-hit != 'true'
run: brew install-bundler-gems
- run: brew test-bot --only-tap-syntax
- run: brew test-bot --only-formulae-detect
id: formulae-detect
- name: generate matrix
id: generate-matrix
run: |
JSON="{\"include\":["
for os in macos-latest ubuntu-latest; do
for formula in $( echo ${{ steps.formulae-detect.outputs.testing_formulae }} | tr ',' ' ' ); do
JSON="$JSON$( jq -nRr '( $ARGS.positional[] | { os: $os, formulae: . }) | tojson' --arg os "$os" --args "$formula" ),"
done
done
if [[ "$JSON" == *, ]]; then
JSON="${JSON%?}"
fi
JSON="$JSON]}"
echo "$JSON"
echo "matrix=$JSON" >> "$GITHUB_OUTPUT"
build-formulae:
name: ${{ matrix.os }}, ${{ matrix.formulae }}
needs: check-generate
runs-on: ${{ matrix.os }}
strategy:
matrix: ${{fromJson(needs.check-generate.outputs.matrix)}}
steps:
- name: Set up Homebrew
id: set-up-homebrew
uses: Homebrew/actions/setup-homebrew@master
with:
core: true
- name: Cache Homebrew Bundler RubyGems
id: cache
uses: actions/cache@v4
with:
path: ${{ steps.set-up-homebrew.outputs.gems-path }}
key: ${{ runner.os }}-rubygems-${{ steps.set-up-homebrew.outputs.gems-hash }}
restore-keys: ${{ runner.os }}-rubygems-
- name: Install Homebrew Bundler RubyGems
if: steps.cache.outputs.cache-hit != 'true'
run: brew install-bundler-gems
- run: brew test-bot --only-cleanup-before
- run: brew test-bot --only-setup
- name: build ${{ matrix.formulae }}
run: |
formula=${{ matrix.formulae }}
case "$formula" in
*-php)
formula="nginx/unit/php-embed,nginx/unit/unit,$formula"
;;
*unit-*)
formula="nginx/unit/unit,$formula"
;;
esac
brew test-bot --only-formulae --testing-formulae="$formula"