File tree Expand file tree Collapse file tree 3 files changed +18
-5
lines changed
Expand file tree Collapse file tree 3 files changed +18
-5
lines changed Original file line number Diff line number Diff line change 1010
1111namespace MaiChartManager ;
1212
13- public class AppMain : ISingleInstance
13+ public partial class AppMain : ISingleInstance
1414{
15- public const string Version = "1.7.2.7" ;
1615 public static Browser ? BrowserWin { get ; set ; }
1716
1817 private Launcher _launcher ;
Original file line number Diff line number Diff line change 1+ // Auto-generated file. Do not modify manually.
2+ namespace MaiChartManager ;
3+
4+ public partial class AppMain
5+ {
6+ public const string Version = "1.7.3" ;
7+ }
Original file line number Diff line number Diff line change @@ -43,16 +43,23 @@ Write-Host "Target Version: $BuildVersion" -ForegroundColor Green
4343# Canary 模式使用完整的 4 段版本号 ($BuildVersion)
4444# Release 模式使用 3 段版本号 ($baseVer)
4545Write-Host " Updating C# source version..." - ForegroundColor Cyan
46- $AppMainPath = " $ProjectRoot \MaiChartManager\AppMain.cs"
47- $AppMainContent = Get-Content $AppMainPath - Raw
46+ $AppMainPath = " $ProjectRoot \MaiChartManager\AppMain.g.cs"
4847
4948if ($Mode -eq " Canary" ) {
5049 $SourceVersion = $BuildVersion
5150} else {
5251 $SourceVersion = $baseVer
5352}
5453
55- $AppMainContent = $AppMainContent -replace ' public const string Version = "[^"]+"' , " public const string Version = "" $SourceVersion "" "
54+ $AppMainContent = @"
55+ // Auto-generated file. Do not modify manually.
56+ namespace MaiChartManager;
57+
58+ public partial class AppMain
59+ {
60+ public const string Version = "$SourceVersion ";
61+ }
62+ "@
5663Set-Content $AppMainPath $AppMainContent - Encoding UTF8
5764
5865
You can’t perform that action at this time.
0 commit comments