🐎 ci: 添加版本信息

This commit is contained in:
imsyy
2023-12-13 10:14:54 +08:00
parent 024ff1773e
commit 2db74f3a39
3 changed files with 18 additions and 12 deletions

View File

@@ -39,15 +39,18 @@ jobs:
path: | path: |
dist/*.exe dist/*.exe
dist/*.msi dist/*.msi
dist/latest.yml
# 创建 GitHub Release # 创建 GitHub Release
- name: Release - name: Release
uses: softprops/action-gh-release@v0.1.15 uses: softprops/action-gh-release@v0.1.15
if: startsWith(github.ref, 'refs/tags/v') if: startsWith(github.ref, 'refs/tags/v')
with: with:
draft: true draft: true
if-no-files-found: ignore
files: | files: |
dist/*.exe dist/*.exe
dist/*.msi dist/*.msi
dist/latest.yml
env: env:
GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }} GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }}
# Mac # Mac
@@ -81,15 +84,18 @@ jobs:
path: | path: |
dist/*.dmg dist/*.dmg
dist/*.zip dist/*.zip
dist/latest-mac.yml
# 创建 GitHub Release # 创建 GitHub Release
- name: Release - name: Release
uses: softprops/action-gh-release@v0.1.15 uses: softprops/action-gh-release@v0.1.15
if: startsWith(github.ref, 'refs/tags/v') if: startsWith(github.ref, 'refs/tags/v')
with: with:
draft: true draft: true
if-no-files-found: ignore
files: | files: |
dist/*.dmg dist/*.dmg
dist/*.zip dist/*.zip
dist/latest-mac.yml
env: env:
GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }} GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }}
# Linux # Linux
@@ -127,15 +133,20 @@ jobs:
dist/*.AppImage dist/*.AppImage
dist/*.deb dist/*.deb
dist/*.rpm dist/*.rpm
dist/*.tar.gz
dist/latest-linux.yml
# 创建 GitHub Release # 创建 GitHub Release
- name: Release - name: Release
uses: softprops/action-gh-release@v0.1.15 uses: softprops/action-gh-release@v0.1.15
if: startsWith(github.ref, 'refs/tags/v') if: startsWith(github.ref, 'refs/tags/v')
with: with:
draft: true draft: true
if-no-files-found: ignore
files: | files: |
dist/*.AppImage dist/*.AppImage
dist/*.deb dist/*.deb
dist/*.rpm dist/*.rpm
dist/*.tar.gz
dist/latest-linux.yml
env: env:
GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }} GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }}

View File

@@ -23,9 +23,7 @@ win:
# 应用程序的图标文件路径 # 应用程序的图标文件路径
icon: public/images/logo/favicon_256.png icon: public/images/logo/favicon_256.png
# 构建类型 # 构建类型
target: target: nsis
- nsis
- portable
# 管理员权限 # 管理员权限
requestedExecutionLevel: highestAvailable requestedExecutionLevel: highestAvailable
# NSIS 安装器配置 # NSIS 安装器配置
@@ -75,7 +73,6 @@ linux:
# 构建类型 # 构建类型
target: target:
- AppImage - AppImage
- snap
- deb - deb
- rpm - rpm
- tar.gz - tar.gz

View File

@@ -88,10 +88,9 @@ class MainProcess {
} }
// 非开发环境启动代理 // 非开发环境启动代理
// if (!is.dev) { if (!is.dev) {
// this.mainServer = await startMainServer(); this.mainServer = await startMainServer();
// } }
this.mainServer = await startMainServer();
// 注册应用协议 // 注册应用协议
app.setAsDefaultProtocolClient("splayer"); app.setAsDefaultProtocolClient("splayer");
@@ -153,10 +152,9 @@ class MainProcess {
this.mainWindow.loadURL(process.env.ELECTRON_RENDERER_URL); this.mainWindow.loadURL(process.env.ELECTRON_RENDERER_URL);
} }
// 生产模式 // 生产模式
// else { else {
// this.mainWindow.loadURL(`http://127.0.0.1:${import.meta.env.MAIN_VITE_MAIN_PORT ?? 7899}`); this.mainWindow.loadURL(`http://127.0.0.1:${import.meta.env.MAIN_VITE_MAIN_PORT ?? 7899}`);
// } }
this.mainWindow.loadURL(`http://127.0.0.1:${import.meta.env.MAIN_VITE_MAIN_PORT ?? 7899}`);
// 监听关闭 // 监听关闭
this.mainWindow.on("close", (event) => { this.mainWindow.on("close", (event) => {