Skip to content

Commit

Permalink
chore: fix release script to work on MacOS
Browse files Browse the repository at this point in the history
  • Loading branch information
rholshausen committed Apr 12, 2024
1 parent a020a1b commit 0b7d0ca
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
6 changes: 5 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,16 @@ on:
release:
types: [published]

concurrency:
group: ci-${{ github.ref }}
cancel-in-progress: false

jobs:
build-release:
runs-on: ${{ matrix.operating-system }}
strategy:
matrix:
operating-system: [ubuntu-latest, windows-latest, macos-latest]
operating-system: [ubuntu-20.04, windows-2019, macos-12]
env:
pact_do_not_track: true
steps:
Expand Down
6 changes: 3 additions & 3 deletions release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,9 @@ case "$1" in
openssl dgst -sha256 -r target/artifacts/pact-protobuf-plugin-macos-x86_64.gz > target/artifacts/pact-protobuf-plugin-macos-x86_64.gz.sha256

# M1
export SDKROOT=$(xcrun -sdk macosx11.1 --show-sdk-path)
export MACOSX_DEPLOYMENT_TARGET=$(xcrun -sdk macosx11.1 --show-sdk-platform-version)
# export SDKROOT=$(xcrun -sdk macosx11.1 --show-sdk-path)
# export MACOSX_DEPLOYMENT_TARGET=$(xcrun -sdk macosx11.1 --show-sdk-platform-version)
export MACOSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET:-12}
cargo build --target aarch64-apple-darwin --release

gzip -c target/aarch64-apple-darwin/release/pact-protobuf-plugin > target/artifacts/pact-protobuf-plugin-osx-aarch64.gz
Expand All @@ -58,4 +59,3 @@ case "$1" in
exit 1
;;
esac

0 comments on commit 0b7d0ca

Please sign in to comment.