Skip to content

2.0.1

2.0.1 #6

Workflow file for this run

name: Release
on:
release:
types: [published]
jobs:
build-release:
name: Build on ${{ matrix.destination.os }}
runs-on: ${{ matrix.destination.os }}
strategy:
matrix:
destination:
- { name: "ubuntu", os: ubuntu-20.04 }
- { name: "macos", os: macos-12 }
steps:
- uses: swift-actions/setup-swift@v1
with:
swift-version: "5.8"
- uses: actions/checkout@v3
- name: Create the binary
run: ./install-script.sh -s . -t mockolo -d . -o mockolo.${{ matrix.destination.name }}.tar.gz
- name: Upload the binary
uses: actions/upload-artifact@v3
with:
name: mockolo.${{ matrix.destination.name }}
path: mockolo.${{ matrix.destination.name }}.tar.gz
check-portability:
needs: build-release
name: TestRun on ${{ matrix.destination.os }}
runs-on: ${{ matrix.destination.os }}
strategy:
matrix:
destination:
- { name: "ubuntu", os: ubuntu-22.04 }
- { name: "ubuntu", os: ubuntu-20.04 }
- { name: "macos", os: macos-12 }
- { name: "macos", os: macos-11 }
steps:
- uses: actions/download-artifact@v3
with:
name: mockolo.${{ matrix.destination.name }}
- name: Unpack the binary
run: tar -xvf mockolo.${{ matrix.destination.name }}.tar.gz
- name: Run the binary
run: ./mockolo --version
deploy-binary:
needs: check-portability
runs-on: ubuntu-latest
steps:
- uses: actions/download-artifact@v3
with:
name: mockolo.ubuntu
- uses: actions/download-artifact@v3
with:
name: mockolo.macos
- name: Deploy the binary
uses: softprops/action-gh-release@v1
with:
files: |
mockolo.ubuntu.tar.gz
mockolo.macos.tar.gz