mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-08-08 20:57:08 +08:00
ci: build macos on pull request (#1854)
This commit is contained in:
@@ -81,6 +81,51 @@ jobs:
|
|||||||
path: ./apps/web/.next
|
path: ./apps/web/.next
|
||||||
if-no-files-found: error
|
if-no-files-found: error
|
||||||
|
|
||||||
|
build-macos:
|
||||||
|
name: Build macOS desktop app
|
||||||
|
runs-on: macos-latest
|
||||||
|
environment: development
|
||||||
|
needs:
|
||||||
|
- build
|
||||||
|
- install-all
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
arch: [arm64]
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- name: Setup Node.js
|
||||||
|
uses: ./.github/actions/setup-node
|
||||||
|
with:
|
||||||
|
electron-workspace-install: true
|
||||||
|
|
||||||
|
- name: Download artifact
|
||||||
|
uses: actions/download-artifact@v3
|
||||||
|
with:
|
||||||
|
name: next-js
|
||||||
|
path: ./apps/web/.next
|
||||||
|
|
||||||
|
- name: install Rust stable
|
||||||
|
uses: dtolnay/rust-toolchain@stable
|
||||||
|
|
||||||
|
- name: add arm64 target
|
||||||
|
if: matrix.arch == 'arm64'
|
||||||
|
run: rustup target add aarch64-apple-darwin
|
||||||
|
|
||||||
|
- name: Rust cache
|
||||||
|
uses: swatinem/rust-cache@v2
|
||||||
|
with:
|
||||||
|
workspaces: './packages/octobase-node -> target'
|
||||||
|
|
||||||
|
- name: make build
|
||||||
|
run: yarn make-macos-${{ matrix.arch }}
|
||||||
|
working-directory: apps/electron
|
||||||
|
|
||||||
|
- name: Upload Artifact
|
||||||
|
uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: affine-darwin-${{ matrix.arch }}-builds
|
||||||
|
path: builds
|
||||||
|
|
||||||
storybook-test:
|
storybook-test:
|
||||||
name: Storybook Test
|
name: Storybook Test
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|||||||
@@ -5,13 +5,15 @@ module.exports = {
|
|||||||
osxSign: {
|
osxSign: {
|
||||||
identity: 'Developer ID Application: TOEVERYTHING PTE. LTD.',
|
identity: 'Developer ID Application: TOEVERYTHING PTE. LTD.',
|
||||||
'hardened-runtime': true,
|
'hardened-runtime': true,
|
||||||
}, // object must exist even if empty
|
|
||||||
osxNotarize: {
|
|
||||||
tool: 'notarytool',
|
|
||||||
appleId: process.env.APPLE_ID,
|
|
||||||
appleIdPassword: process.env.APPLE_PASSWORD,
|
|
||||||
teamId: process.env.APPLE_TEAM_ID,
|
|
||||||
},
|
},
|
||||||
|
osxNotarize: process.env.APPLE_ID
|
||||||
|
? {
|
||||||
|
tool: 'notarytool',
|
||||||
|
appleId: process.env.APPLE_ID,
|
||||||
|
appleIdPassword: process.env.APPLE_PASSWORD,
|
||||||
|
teamId: process.env.APPLE_TEAM_ID,
|
||||||
|
}
|
||||||
|
: undefined,
|
||||||
},
|
},
|
||||||
makers: [
|
makers: [
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user