Skip to content

Fix: replaced underscores with dashes in links #6

Fix: replaced underscores with dashes in links

Fix: replaced underscores with dashes in links #6

name: Build Swift scripts
on:
workflow_dispatch:
push:
branches:
- main
paths:
- '**.swift'
pull_request:
branches:
- main
paths:
- '**.swift'
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [macos-14, macos-15, ubuntu-latest] # macos 15 comes with Swift 6 which has breaking changes vs Swift 5.*
fail-fast: false
steps:
- name: Checkout code
uses: actions/checkout@v4.2.2
- name: Print Swift version
run: swift --version
- name: Build Swift scripts
run: swiftc scripts/*.swift || exit 1
check-builds:
needs: build
runs-on: ubuntu-latest
if: always()
steps:
- name: Check build matrix status
run: |
if [[ "${{ needs.build.result }}" == "failure" || "${{ needs.build.result }}" == "cancelled" ]]; then
echo "One or more builds failed"
exit 1
fi