mirror of
https://github.com/pompurin404/mihomo-party.git
synced 2024-11-16 11:42:19 +08:00
116 lines
2.5 KiB
YAML
116 lines
2.5 KiB
YAML
name: Build
|
|
on:
|
|
push:
|
|
branches:
|
|
- master
|
|
permissions: write-all
|
|
|
|
jobs:
|
|
windows:
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
arch:
|
|
- x64
|
|
- ia32
|
|
- arm64
|
|
runs-on: windows-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
with:
|
|
fetch-depth: 0
|
|
- name: Setup Nodejs
|
|
uses: actions/setup-node@v4
|
|
with:
|
|
node-version: 22
|
|
- name: Setup pnpm
|
|
uses: pnpm/action-setup@v4
|
|
with:
|
|
version: 9
|
|
- name: Install Dependencies
|
|
run: |
|
|
pnpm install
|
|
pnpm prepare --${{ matrix.arch }}
|
|
- name: Build
|
|
run: pnpm build:win --${{ matrix.arch }}
|
|
|
|
- name: Upload Artifacts
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: Windows ${{ matrix.arch }}
|
|
path: dist/*.exe
|
|
if-no-files-found: error
|
|
|
|
linux:
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
arch:
|
|
- x64
|
|
- arm64
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
with:
|
|
fetch-depth: 0
|
|
- name: Setup Nodejs
|
|
uses: actions/setup-node@v4
|
|
with:
|
|
node-version: 22
|
|
- name: Setup pnpm
|
|
uses: pnpm/action-setup@v4
|
|
with:
|
|
version: 9
|
|
- name: Install Dependencies
|
|
run: |
|
|
pnpm install
|
|
pnpm prepare --${{ matrix.arch }}
|
|
- name: Build
|
|
run: pnpm build:linux --${{ matrix.arch }}
|
|
|
|
- name: Upload Artifacts
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: Linux ${{ matrix.arch }}
|
|
path: |
|
|
dist/*.deb
|
|
dist/*.rpm
|
|
if-no-files-found: error
|
|
|
|
macos:
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
arch:
|
|
- x64
|
|
- arm64
|
|
runs-on: macos-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
with:
|
|
fetch-depth: 0
|
|
- name: Setup Nodejs
|
|
uses: actions/setup-node@v4
|
|
with:
|
|
node-version: 22
|
|
- name: Setup pnpm
|
|
uses: pnpm/action-setup@v4
|
|
with:
|
|
version: 9
|
|
- name: Install Dependencies
|
|
run: |
|
|
pnpm install
|
|
pnpm prepare --${{ matrix.arch }}
|
|
- name: Build
|
|
run: pnpm build:mac --${{ matrix.arch }}
|
|
|
|
- name: Upload Artifacts
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: MacOS ${{ matrix.arch }}
|
|
path: dist/*.dmg
|
|
if-no-files-found: error
|