forked from xiaoY233/Chat2API
-
Notifications
You must be signed in to change notification settings - Fork 0
55 lines (46 loc) · 1.36 KB
/
Copy pathrelease.yml
File metadata and controls
55 lines (46 loc) · 1.36 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
name: Release
on:
workflow_dispatch:
push:
tags:
- 'v*.*.*'
- 'v*.*.*-*'
jobs:
release:
runs-on: ${{ matrix.os }}
permissions:
contents: write
actions: write
strategy:
matrix:
include:
- os: windows-latest
arch: x64
- os: ubuntu-latest
arch: x64
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'npm'
- name: Install dependencies
run: npm ci
env:
ELECTRON_MIRROR: https://github.com/electron/electron/releases/download/
- name: Build application
run: npm run build
- name: Build and Publish (Windows)
if: matrix.os == 'windows-latest'
run: npx electron-builder --win --${{ matrix.arch }} --publish=always
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
ELECTRON_MIRROR: https://github.com/electron/electron/releases/download/
- name: Build and Publish (Linux)
if: matrix.os == 'ubuntu-latest'
run: npx electron-builder --linux --${{ matrix.arch }} --publish=always
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
ELECTRON_MIRROR: https://github.com/electron/electron/releases/download/