Skip to content

Commit

Permalink
use separate runners for macos arm and x64
Browse files Browse the repository at this point in the history
  • Loading branch information
JovannMC committed Nov 16, 2024
1 parent e1edfef commit 6eee88e
Show file tree
Hide file tree
Showing 2 changed files with 40 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:
branches:
- main
paths:
- ".github/workflows/build-mac.yml"
- ".github/workflows/build-mac-arm64.yml"
- package.json
workflow_dispatch:
create:
Expand All @@ -29,18 +29,9 @@ jobs:
- name: Build the application
run: npm run build

- name: Compress macOS build artifacts (x64)
run: zip -r build/SlimeTora-darwin-x64.zip build/SlimeTora-darwin-x64

- name: Compress macOS build artifacts (arm64)
run: zip -r build/SlimeTora-darwin-arm64.zip build/SlimeTora-darwin-arm64

- name: Archive build artifacts for macOS (x64)
uses: actions/upload-artifact@v4
with:
name: build-artifacts-macos-x64
path: build/SlimeTora-darwin-x64.zip

- name: Archive build artifacts for macOS (arm64)
uses: actions/upload-artifact@v4
with:
Expand Down
39 changes: 39 additions & 0 deletions .github/workflows/build-mac-x64.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Build application (macOS)

on:
push:
branches:
- main
paths:
- ".github/workflows/build-mac-x64.yml"
- package.json
workflow_dispatch:
create:

jobs:
build:
runs-on: macos-13

steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: "20"

- name: Install Node.js dependencies
run: npm install

- name: Build the application
run: npm run build

- name: Compress macOS build artifacts (x64)
run: zip -r build/SlimeTora-darwin-x64.zip build/SlimeTora-darwin-x64

- name: Archive build artifacts for macOS (x64)
uses: actions/upload-artifact@v4
with:
name: build-artifacts-macos-x64
path: build/SlimeTora-darwin-x64.zip

0 comments on commit 6eee88e

Please sign in to comment.