From 68d5c778cf2a0ea90a3756a3074e7211a9aab88b Mon Sep 17 00:00:00 2001 From: MarkSackerberg <93528482+MarkSackerberg@users.noreply.github.com> Date: Mon, 18 Mar 2024 10:24:04 +0100 Subject: [PATCH 1/5] Update build.yml --- .github/workflows/build.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 7549f431..25e5e0f6 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -17,6 +17,7 @@ jobs: - windows-latest - ubuntu-latest - macos-latest + - macos-14 runs-on: ${{ matrix.os }} @@ -49,6 +50,8 @@ jobs: if [[ "${RUNNER_OS}" == "Windows" ]]; then binary_extension=".exe" binary_path="sugar-windows-latest${binary_extension}" + elif [[ "${RUNNER_OS}" == "macOS-14" ]]; then + binary_path="sugar-macos-m1-latest" elif [[ "${RUNNER_OS}" == "macOS" ]]; then binary_path="sugar-macos-intel-latest" elif [[ "${RUNNER_OS}" == "Linux" ]]; then From a36d736bcc41ce0a10f65417671c22b8fdb64985 Mon Sep 17 00:00:00 2001 From: MarkSackerberg <93528482+MarkSackerberg@users.noreply.github.com> Date: Mon, 18 Mar 2024 10:47:23 +0100 Subject: [PATCH 2/5] use architecture --- .github/workflows/build.yml | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 25e5e0f6..12cf9e1b 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -53,7 +53,15 @@ jobs: elif [[ "${RUNNER_OS}" == "macOS-14" ]]; then binary_path="sugar-macos-m1-latest" elif [[ "${RUNNER_OS}" == "macOS" ]]; then - binary_path="sugar-macos-intel-latest" + arch=$(uname -m) + if [[ "${arch}" == "x86_64" ]]; then + binary_path="sugar-macos-intel-latest" + elif [[ "${arch}" == "arm64" ]]; then + binary_path="sugar-macos-m1-latest" + else + echo "error: unknown macOS architecture: ${arch}" + exit 1 + fi elif [[ "${RUNNER_OS}" == "Linux" ]]; then binary_path="sugar-ubuntu-latest" else From 75c44c0e765ffee51c248189f718eb730a5e2890 Mon Sep 17 00:00:00 2001 From: MarkSackerberg <93528482+MarkSackerberg@users.noreply.github.com> Date: Mon, 18 Mar 2024 11:19:04 +0100 Subject: [PATCH 3/5] Update build.yml --- .github/workflows/build.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 12cf9e1b..493093fa 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -50,8 +50,6 @@ jobs: if [[ "${RUNNER_OS}" == "Windows" ]]; then binary_extension=".exe" binary_path="sugar-windows-latest${binary_extension}" - elif [[ "${RUNNER_OS}" == "macOS-14" ]]; then - binary_path="sugar-macos-m1-latest" elif [[ "${RUNNER_OS}" == "macOS" ]]; then arch=$(uname -m) if [[ "${arch}" == "x86_64" ]]; then From 5801dcbbd9e37cc69e4b4c72f84846d51e1130d3 Mon Sep 17 00:00:00 2001 From: MarkSackerberg <93528482+MarkSackerberg@users.noreply.github.com> Date: Mon, 18 Mar 2024 12:47:17 +0100 Subject: [PATCH 4/5] Update build.yml --- .github/workflows/build.yml | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 493093fa..b98b5b4d 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -21,6 +21,9 @@ jobs: runs-on: ${{ matrix.os }} + env: + MATRIX_OS: ${{ matrix.os }} + steps: - name: Checkout uses: actions/checkout@v3 @@ -51,14 +54,10 @@ jobs: binary_extension=".exe" binary_path="sugar-windows-latest${binary_extension}" elif [[ "${RUNNER_OS}" == "macOS" ]]; then - arch=$(uname -m) - if [[ "${arch}" == "x86_64" ]]; then - binary_path="sugar-macos-intel-latest" - elif [[ "${arch}" == "arm64" ]]; then + if [[ "${MATRIX_OS}" == "macos-14" ]]; then binary_path="sugar-macos-m1-latest" else - echo "error: unknown macOS architecture: ${arch}" - exit 1 + binary_path="sugar-macos-intel-latest" fi elif [[ "${RUNNER_OS}" == "Linux" ]]; then binary_path="sugar-ubuntu-latest" From 49a06fdba278a6d8a71b8369664d0c48fd060517 Mon Sep 17 00:00:00 2001 From: MarkSackerberg <93528482+MarkSackerberg@users.noreply.github.com> Date: Mon, 18 Mar 2024 13:18:55 +0100 Subject: [PATCH 5/5] revert to fully architecture based naming