🚀 v0.8.2

This commit is contained in:
BTMuli
2025-09-27 10:23:25 +08:00
parent 4cbd8af250
commit 76e9d23f23
9 changed files with 55 additions and 104 deletions

View File

@@ -3,6 +3,11 @@ on:
push:
tags:
- v*
workflow_dispatch:
inputs:
tag:
description: "Tag to release"
required: false
jobs:
publish-tauri:
@@ -18,7 +23,7 @@ jobs:
- platform: macos-latest
args: "--target x86_64-apple-darwin"
target: "macos-intel"
- platform: macos-latest
- platform: macos-15-intel
args: "--target aarch64-apple-darwin"
target: "macos-arm"
runs-on: ${{ matrix.settings.platform }}
@@ -27,19 +32,16 @@ jobs:
- name: Checkout
uses: actions/checkout@v4
- name: Setup SSH
uses: webfactory/ssh-agent@v0.9.0
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}
- name: Add SSH known hosts
run: ssh-keyscan -t rsa github.com >> ~/.ssh/known_hosts
run: |
mkdir -p ~/.ssh
echo "${{ secrets.SSH_PRIVATE_KEY }}" | tr -d '\r' > ~/.ssh/id_rsa
chmod 600 ~/.ssh/id_rsa
- name: Add Github RSA
run: |
echo "${{ secrets.KNOWN_GITHUB_RSA }}" >> ~/.ssh/known_hosts
chmod 644 ~/.ssh/known_hosts
- name: Test SSH connection
run: ssh -T git@github.com || true
- name: Add Rust targets(macOS Intel)
if: matrix.settings.target == 'macos-intel'
run: rustup target add x86_64-apple-darwin
- name: Add Rust targets(macOS ARM)
if: matrix.settings.target == 'macos-arm'
run: rustup target add aarch64-apple-darwin
- name: Rust setup
uses: dtolnay/rust-toolchain@stable
@@ -48,14 +50,23 @@ jobs:
with:
workspaces: "./src-tauri -> target"
- name: Add Rust targets(macOS Intel)
if: matrix.settings.target == 'macos-intel'
run: rustup target add x86_64-apple-darwin
- name: Add Rust targets(macOS ARM)
if: matrix.settings.target == 'macos-arm'
run: rustup target add aarch64-apple-darwin
- name: Output toolchain
run: rustup show
- name: setup node
uses: actions/setup-node@v3
with:
node-version: 24.2.0
node-version: 24.8.0
- name: setup pnpm
uses: pnpm/action-setup@v2
with:
version: 10.15.1
version: 10.16.1
- name: Install frontend dependencies
run: pnpm install

View File

@@ -12,11 +12,11 @@ jobs:
- name: setup node
uses: actions/setup-node@v3
with:
node-version: 23.3.0
node-version: 24.8.0
- name: setup pnpm
uses: pnpm/action-setup@v2
with:
version: 10.10.0
version: 10.16.1
- name: Install dependencies
run: pnpm install --no-frozen-lockfile
- name: "Qodana Scan"

View File

@@ -1,78 +0,0 @@
name: Build Test
on:
workflow_dispatch:
inputs:
version:
description: "Version to build"
required: true
default: "0.7.6"
jobs:
build-tauri:
permissions:
contents: write
strategy:
fail-fast: false
matrix:
settings:
- platform: windows-latest
args: ""
target: "windows"
bundlePath: msi/
- platform: macos-latest
args: "x86_64-apple-darwin"
target: "macos-intel"
bundlePath: macos/TeyvatGuide.app
- platform: macos-latest
args: "aarch64-apple-darwin"
target: "macos-arm"
bundlePath: macos/TeyvatGuide.app
runs-on: ${{ matrix.settings.platform }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup SSH
uses: webfactory/ssh-agent@v0.9.0
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}
- name: Add SSH known hosts
run: ssh-keyscan -t rsa github.com >> ~/.ssh/known_hosts
- name: Test SSH connection
run: ssh -T git@github.com || true
- name: Rust setup
uses: dtolnay/rust-toolchain@stable
- name: Add Rust targets(macOS Intel)
if: matrix.settings.target == 'macos-intel'
run: rustup target add x86_64-apple-darwin
- name: Add Rust targets(macOS ARM)
if: matrix.settings.target == 'macos-arm'
run: rustup target add aarch64-apple-darwin
- name: setup node
uses: actions/setup-node@v3
with:
node-version: 23.3.0
- name: setup pnpm
uses: pnpm/action-setup@v2
with:
version: 10.10.0
- name: Install frontend dependencies
run: pnpm install
- name: Update version
run: pnpm upv ${{ github.event.inputs.version }}
- name: Build app
run: pnpm build --target ${{ matrix.settings.args }}
if: matrix.settings.args != ''
- name: Build app (no target)
run: pnpm build
if: matrix.settings.args == ''
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: TeyvatGuide_v${{ github.event.inputs.version }}_${{ matrix.settings.target }}
path: src-tauri/target/${{ matrix.settings.args }}/release/bundle/${{ matrix.settings.bundlePath }}
if-no-files-found: error