ci(release): 调整CI构建配置并完善签名配置
1. 移除了macOS Intel架构的构建任务 2. 调整了安装步骤的顺序,先安装Node再安装pnpm 3. 新增macOS Apple Silicon架构的rust target添加步骤 4. 配置了Tauri打包所需的签名密钥环境变量
This commit is contained in:
parent
d070ea8aa7
commit
2b98927bb8
|
|
@ -19,10 +19,6 @@ jobs:
|
||||||
- platform: "macos-latest"
|
- platform: "macos-latest"
|
||||||
args: "--target aarch64-apple-darwin"
|
args: "--target aarch64-apple-darwin"
|
||||||
|
|
||||||
# macOS Intel
|
|
||||||
- platform: "macos-latest"
|
|
||||||
args: "--target x86_64-apple-darwin"
|
|
||||||
|
|
||||||
# Windows x64
|
# Windows x64
|
||||||
- platform: "windows-latest"
|
- platform: "windows-latest"
|
||||||
args: ""
|
args: ""
|
||||||
|
|
@ -34,22 +30,27 @@ jobs:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v5
|
uses: actions/checkout@v5
|
||||||
|
|
||||||
# 3. 安装 Node.js
|
# 2. 安装 Node.js
|
||||||
- name: Install pnpm
|
|
||||||
uses: pnpm/action-setup@v6
|
|
||||||
with:
|
|
||||||
version: 11
|
|
||||||
|
|
||||||
- name: Setup Node
|
- name: Setup Node
|
||||||
uses: actions/setup-node@v5
|
uses: actions/setup-node@v5
|
||||||
with:
|
with:
|
||||||
node-version: lts/*
|
node-version: lts/*
|
||||||
cache: "pnpm"
|
cache: "pnpm"
|
||||||
|
|
||||||
|
# 3. 安装 pnpm
|
||||||
|
- name: Install pnpm
|
||||||
|
uses: pnpm/action-setup@v6
|
||||||
|
with:
|
||||||
|
version: 11
|
||||||
|
|
||||||
# 4. 安装 Rust
|
# 4. 安装 Rust
|
||||||
- name: Setup Rust
|
- name: Setup Rust
|
||||||
uses: dtolnay/rust-toolchain@stable
|
uses: dtolnay/rust-toolchain@stable
|
||||||
|
|
||||||
|
- name: Add macOS Apple Silicon target
|
||||||
|
if: matrix.platform == 'macos-latest'
|
||||||
|
run: rustup target add aarch64-apple-darwin
|
||||||
|
|
||||||
# 5. Rust 缓存(大幅加速后续构建)
|
# 5. Rust 缓存(大幅加速后续构建)
|
||||||
- name: Cache Rust build
|
- name: Cache Rust build
|
||||||
uses: Swatinem/rust-cache@v2
|
uses: Swatinem/rust-cache@v2
|
||||||
|
|
@ -65,6 +66,8 @@ jobs:
|
||||||
uses: tauri-apps/tauri-action@v0
|
uses: tauri-apps/tauri-action@v0
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY }}
|
||||||
|
TAURI_SIGNING_PRIVATE_KEY_PASSWORD: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY_PASSWORD }}
|
||||||
with:
|
with:
|
||||||
tagName: v__VERSION__ # 自动替换为 tauri.conf.json 里的版本号
|
tagName: v__VERSION__ # 自动替换为 tauri.conf.json 里的版本号
|
||||||
releaseName: "StealthReader v__VERSION__"
|
releaseName: "StealthReader v__VERSION__"
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue