Skip to content

Commit

Permalink
ci: 依旧尝试解决安装后应用图标确实问题; 并更新下cd文件, 使其无需上传太大的包
Browse files Browse the repository at this point in the history
  • Loading branch information
LuSrackhall committed Aug 24, 2024
1 parent 31e11e4 commit 5c9ab87
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 32 deletions.
62 changes: 31 additions & 31 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,39 +44,39 @@ jobs:
sudo apt install libasound2-dev
make linux
- name: Debug Generated Build
uses: actions/upload-artifact@v3 # 安装用于上传最终打包结果到执行完毕界面的脚本
with:
name: elect
path: frontend/dist/electron/*

# - name: Find the generated installer && ZIP the generated installer
# working-directory: frontend/dist/electron/Packaged
# shell: bash # 由于我们下方要使用的find命令, powershell中没有(更重要的是, 我不喜欢powershell) # 这个指定, 应该会让我们使用git-bash。
# run:
# | # 由于find -name 'KeyTone-Setup-*-win.exe'得到的结果为./KeyTone-Setup-*-win.exe , 而我们不需要./ , 因此使用basename提取文件名
# INSTALLER_NAME_TARGZ=$(basename $(find -name 'KeyTone-*-linux-*.tar.gz'))
# echo "INSTALLER_NAME_TARGZ=$INSTALLER_NAME_TARGZ" >> $GITHUB_ENV
# INSTALLER_NAME_APPIMAGE=$(basename $(find -name 'KeyTone-*-linux-*.AppImage'))
# echo "INSTALLER_NAME_APPIMAGE=$INSTALLER_NAME_APPIMAGE" >> $GITHUB_ENV
# INSTALLER_NAME_DEB=$(basename $(find -name 'KeyTone-*-linux-*.deb'))
# echo "INSTALLER_NAME_DEB=$INSTALLER_NAME_DEB" >> $GITHUB_ENV

# - name: Upload Build Artifact Tar.gz
# uses: actions/upload-artifact@v3 # 安装用于上传最终打包结果到执行完毕界面的脚本
# with:
# name: ${{ env.INSTALLER_NAME_TARGZ }}
# path: frontend/dist/electron/Packaged/${{ env.INSTALLER_NAME_TARGZ }}
# - name: Upload Build Artifact AppImage
# uses: actions/upload-artifact@v3 # 安装用于上传最终打包结果到执行完毕界面的脚本
# with:
# name: ${{ env.INSTALLER_NAME_APPIMAGE }}
# path: frontend/dist/electron/Packaged/${{ env.INSTALLER_NAME_APPIMAGE }}
# - name: Upload Build Artifact Deb
# - name: Debug Generated Build
# uses: actions/upload-artifact@v3 # 安装用于上传最终打包结果到执行完毕界面的脚本
# with:
# name: ${{ env.INSTALLER_NAME_DEB }}
# path: frontend/dist/electron/Packaged/${{ env.INSTALLER_NAME_DEB }}
# name: elect
# path: frontend/dist/electron/*

- name: Find the generated installer && ZIP the generated installer
working-directory: frontend/dist/electron/Packaged
shell: bash # 由于我们下方要使用的find命令, powershell中没有(更重要的是, 我不喜欢powershell) # 这个指定, 应该会让我们使用git-bash。
run:
| # 由于find -name 'KeyTone-Setup-*-win.exe'得到的结果为./KeyTone-Setup-*-win.exe , 而我们不需要./ , 因此使用basename提取文件名
INSTALLER_NAME_TARGZ=$(basename $(find -name 'KeyTone-*-linux*tar.gz'))
echo "INSTALLER_NAME_TARGZ=$INSTALLER_NAME_TARGZ" >> $GITHUB_ENV
INSTALLER_NAME_APPIMAGE=$(basename $(find -name 'KeyTone-*-linux*AppImage'))
echo "INSTALLER_NAME_APPIMAGE=$INSTALLER_NAME_APPIMAGE" >> $GITHUB_ENV
INSTALLER_NAME_DEB=$(basename $(find -name 'KeyTone-*-linux*deb'))
echo "INSTALLER_NAME_DEB=$INSTALLER_NAME_DEB" >> $GITHUB_ENV

- name: Upload Build Artifact Tar.gz
uses: actions/upload-artifact@v3 # 安装用于上传最终打包结果到执行完毕界面的脚本
with:
name: ${{ env.INSTALLER_NAME_TARGZ }}
path: frontend/dist/electron/Packaged/${{ env.INSTALLER_NAME_TARGZ }}
- name: Upload Build Artifact AppImage
uses: actions/upload-artifact@v3 # 安装用于上传最终打包结果到执行完毕界面的脚本
with:
name: ${{ env.INSTALLER_NAME_APPIMAGE }}
path: frontend/dist/electron/Packaged/${{ env.INSTALLER_NAME_APPIMAGE }}
- name: Upload Build Artifact Deb
uses: actions/upload-artifact@v3 # 安装用于上传最终打包结果到执行完毕界面的脚本
with:
name: ${{ env.INSTALLER_NAME_DEB }}
path: frontend/dist/electron/Packaged/${{ env.INSTALLER_NAME_DEB }}

# - name: Calculate File Hashes
# shell: bash
Expand Down
2 changes: 1 addition & 1 deletion frontend/quasar.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ module.exports = configure(function (/* ctx */) {

linux: {
// icon: 'src/assets/icon.icns', // 某些应用模板或框架(如 Quasar),已经在项目中包含了默认的图标文件,并在构建过程中自动配置好了这些图标, 因此无需在此处配置。
icon: 'src/assets/img/KeyTone.png', // 由于在Ubuntu上安装后, 没有图标, 因此我尝试指定它来解决这个问题。
icon: 'icons/icon.icns', // 由于在Ubuntu上安装后, 没有图标, 因此我尝试指定它来解决这个问题。
category: 'Utility', // 指定应用在 Linux 应用菜单中的分类。Utility 是一个常见的类别,表示工具类应用。此配置有助于将应用放置在合适的类别中,使用户更容易找到。
executableName: 'keytone', // 定义构建后可执行文件的名称。在你的例子中,构建后的可执行文件将命名为 Keytone。在 Linux 中,用户通常通过这个名称来启动应用, 因此常用纯小写来命名。

Expand Down

0 comments on commit 5c9ab87

Please sign in to comment.