Skip to content

Commit

Permalink
fix:修改工作流文件 (#20)
Browse files Browse the repository at this point in the history
* feat:添加构建桌面端工作流

* fix:修改node版本

* fix:修改工作流文件

* fix:修改工作流文件

* fix:调整版本

* fix:修改工作流文件
  • Loading branch information
zwtesttt authored May 31, 2024
1 parent 75badd3 commit 5ab1b9c
Show file tree
Hide file tree
Showing 2 changed files with 37 additions and 1 deletion.
35 changes: 35 additions & 0 deletions .github/workflows/build-electron.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: Build/release

on:
push:
tags:
- 'v*.*.*' # 只在 tag push 时触发工作流

jobs:
release:
permissions: write-all
runs-on: ${{ matrix.os }}

strategy:
matrix:
os: [macos-latest, ubuntu-latest, windows-latest]

steps:
- name: Check out Git repository
uses: actions/checkout@v1

- name: Install Node.js, NPM and Yarn
uses: actions/setup-node@v1
with:
node-version: 20

- name: Build/release Electron app
uses: Yan-Jobs/[email protected]
with:
# GitHub token, automatically provided to the action
# (No need to define this secret in the repo settings)
github_token: ${{ secrets.github_token }}
# If the commit is tagged with a version (e.g. "v1.0.0"),
# release the app after building
release: ${{ startsWith(github.ref, 'refs/tags/v') }}
build_script_name: build:electron
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "coss-client",
"version": "0.0.0",
"version": "1.0.0",
"type": "module",
"description": "coss 及时通讯的客户端",
"keywords": [
Expand All @@ -25,6 +25,7 @@
"build": "tsc && vite build",
"build:electron": "tsc && vite build -c vite.electron.config.ts && electron-builder",
"build:mobile": "npm run build && npx cap sync",
"build:action": "tsc && vite build -c vite.electron.config.ts",
"lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0",
"preview": "vite preview",
"translate": "node node_modules/vue-auto-translate/server.js",
Expand Down

0 comments on commit 5ab1b9c

Please sign in to comment.