完善CI构建。
Some checks failed
Release tag / build (push) Failing after 49s

This commit is contained in:
amass 2024-11-14 12:11:59 +08:00
parent 27e5db45d6
commit d6a36c0450
3 changed files with 8 additions and 7 deletions

View File

@ -20,4 +20,4 @@ jobs:
with: with:
body_path: build/CHANGELOG.txt body_path: build/CHANGELOG.txt
files: |- files: |-
build/AntiClipSettings.zip build/视觉防夹设备上位机工具*.zip

View File

@ -40,7 +40,7 @@ Application::Application(int &argc, char **argv)
font.setFamily("微软雅黑"); font.setFamily("微软雅黑");
m_app->setFont(font); m_app->setFont(font);
m_app->setApplicationName(APPLICATION_NAME); m_app->setApplicationName(APPLICATION_NAME);
m_app->setApplicationVersion(QString("V%1").arg(APP_VERSION)); m_app->setApplicationVersion(QString("v%1").arg(APP_VERSION));
m_player->open(); m_player->open();
} }

View File

@ -1,4 +1,5 @@
param($type) param($type)
# 该脚本设置为 UTF8-bom 编码即可支持中文
$MsvcScript = 'D:\Program Files\Microsoft Visual Studio\2022\\Community\Common7\Tools\Launch-VsDevShell.ps1' $MsvcScript = 'D:\Program Files\Microsoft Visual Studio\2022\\Community\Common7\Tools\Launch-VsDevShell.ps1'
if (!(Test-Path $MsvcScript)) { $MsvcScript = 'D:\Program Files\Microsoft Visual Studio\2022\\Professional\Common7\Tools\Launch-VsDevShell.ps1' } if (!(Test-Path $MsvcScript)) { $MsvcScript = 'D:\Program Files\Microsoft Visual Studio\2022\\Professional\Common7\Tools\Launch-VsDevShell.ps1' }
@ -24,8 +25,8 @@ if ($fileContent -match 'project\([^\)]+VERSION\s+([0-9]+\.[0-9]+)') {
Write-Output "未找到版本号" Write-Output "未找到版本号"
} }
$deployPath = Join-Path -Path $buildPath -ChildPath "AntiClipSettings_v$version" $deployPath = Join-Path -Path $buildPath -ChildPath "视觉防夹设备上位机工具v$version"
$zipFilePath = Join-Path -Path $buildPath -ChildPath "AntiClipSettings_v$version.zip" $zipFilePath = Join-Path -Path $buildPath -ChildPath "视觉防夹设备上位机工具v$version.zip"
$changelogPath = Join-Path -Path $buildPath -ChildPath "CHANGELOG.txt" $changelogPath = Join-Path -Path $buildPath -ChildPath "CHANGELOG.txt"
function Build() { function Build() {
@ -46,8 +47,8 @@ function Deploy() {
Remove-Item $deployPath -Recurse -Force Remove-Item $deployPath -Recurse -Force
} }
New-Item $deployPath -ItemType Directory New-Item $deployPath -ItemType Directory
Copy-Item $buildPath\AntiClipSettings.exe $deployPath\AntiClipSettings.exe Copy-Item $buildPath\AntiClipSettings.exe $deployPath\视觉防夹设备上位机工具v$version.exe
& $qtHome\bin\windeployqt.exe $deployPath\AntiClipSettings.exe --qmldir=$qtHome\qml & $qtHome\bin\windeployqt.exe $deployPath\视觉防夹设备上位机工具v$version.exe --qmldir=$qtHome\qml
Remove-Item -Path $deployPath\d3dcompiler_47.dll -Force Remove-Item -Path $deployPath\d3dcompiler_47.dll -Force
Remove-Item -Path $deployPath\Qt5RemoteObjects.dll -Force Remove-Item -Path $deployPath\Qt5RemoteObjects.dll -Force
Remove-Item -Path $deployPath\Qt5QuickTest.dll -Force Remove-Item -Path $deployPath\Qt5QuickTest.dll -Force