ci: 🔧 Update ci

This commit is contained in:
viarotel 2024-10-28 17:00:53 +08:00
parent cc1d7c5cc4
commit e0eb73bbaf
3 changed files with 20 additions and 10 deletions

View File

@ -27,24 +27,29 @@ jobs:
with:
node-version: 20
- name: Enable corepack and pnpm
run: |
corepack enable
corepack prepare pnpm@latest --activate
- name: Install Dependencies
run: npm install
run: pnpm install
- name: build-linux
if: matrix.os == 'ubuntu-latest'
run: npm run build:linux
run: pnpm build:linux
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}
- name: build-mac
if: matrix.os == 'macos-latest'
run: npm run build:mac
run: pnpm build:mac
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}
- name: build-win
if: matrix.os == 'windows-latest'
run: npm run build:win
run: pnpm build:win
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}

7
.npmrc
View File

@ -1,7 +1,4 @@
registry=https://registry.npmmirror.com/
# 国内用户如果遇到无法安装依赖的情况,请将 .npmrc.CN 中的配置覆盖到本文件中
shamefully-hoist=true
virtual-store-dir-max-length=70
ELECTRON_MIRROR=https://npmmirror.com/mirrors/electron/
ELECTRON_CUSTOM_DIR="{{ version }}"
ELECTRON_BUILDER_BINARIES_MIRROR=https://npmmirror.com/mirrors/electron-builder-binaries/

8
.npmrc.CN Normal file
View File

@ -0,0 +1,8 @@
shamefully-hoist=true
virtual-store-dir-max-length=70
registry=https://registry.npmmirror.com/
ELECTRON_MIRROR=https://npmmirror.com/mirrors/electron/
ELECTRON_CUSTOM_DIR="{{ version }}"
ELECTRON_BUILDER_BINARIES_MIRROR=https://npmmirror.com/mirrors/electron-builder-binaries/