This repository was archived by the owner on May 7, 2026. It is now read-only.
File tree Expand file tree Collapse file tree
KeySwitchManager/Sources/Runtime/Applications Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -58,15 +58,15 @@ jobs:
5858 dotnet-version : ${{ env.DOTNET_SDK_VERSION }}
5959
6060 - name : CLI Build
61- run : dotnet msbuild /nologo /t:Archive /p:Configuration=${{ inputs.build-configuration }} /p:PublishDir=${{ github.workspace }}/publish $ProjectFile
61+ run : dotnet msbuild /nologo /t:Archive /p:Configuration=${{ inputs.build-configuration }} /p:PublishDir=${{ github.workspace }}/publish /p:GitBranch=${{ github.ref }} /p:GitCommitHash=${{ github.sha }} $ProjectFile
6262 shell : bash
6363 env :
6464 ProjectFile : KeySwitchManager/Sources/Runtime/Applications/CLI/publish.msbuild
6565
6666 - name : Artifact CLI
6767 uses : actions/upload-artifact@v3
6868 with :
69- name : KeySwitchManager.CLI-${{ inputs.build-configuration }}${{ inputs.custom-suffix }}-${{ github.sha }}
69+ name : KeySwitchManager.CLI-${{ inputs.build-configuration }}${{ inputs.custom-suffix }}
7070 path : ${{ github.workspace }}/publish/KeySwitchManager.CLI*/
7171
7272 # --------------------------------------------------------------
@@ -89,13 +89,13 @@ jobs:
8989 dotnet-version : ${{ env.DOTNET_SDK_VERSION }}
9090
9191 - name : WPF Build
92- run : dotnet msbuild /nologo /t:Archive /p:Configuration=${{ inputs.build-configuration }} /p:PublishDir=${{ github.workspace }}/publish %ProjectFile%
92+ run : dotnet msbuild /nologo /t:Archive /p:Configuration=${{ inputs.build-configuration }} /p:PublishDir=${{ github.workspace }}/publish /p:GitBranch=${{ github.ref }} /p:GitCommitHash=${{ github.sha }} %ProjectFile%
9393 shell : cmd
9494 env :
9595 ProjectFile : KeySwitchManager/Sources/Runtime/Applications/WPF/publish.msbuild
9696
9797 - name : Artifact WPF
9898 uses : actions/upload-artifact@v3
9999 with :
100- name : KeySwitchManager.WPF-${{ inputs.build-configuration }}${{ inputs.custom-suffix }}-${{ github.sha }}
100+ name : KeySwitchManager.WPF-${{ inputs.build-configuration }}${{ inputs.custom-suffix }}
101101 path : ${{ github.workspace }}/publish/KeySwitchManager.WPF*/
Original file line number Diff line number Diff line change @@ -13,9 +13,18 @@ $(Product)
1313
1414%(MyAssemblyIdentities.Version)
1515
16- ## Build At
16+ ## Build On
1717
18- $([System.DateTime]::Now.ToString("yyyy-MM-dd HH:mm:ss %K"))
18+ $([System.DateTime]::UtcNow.ToString("yyyy-MM-ddTHH:mm:ss"))
19+
20+ ## Build Configuration
21+
22+ $(Configuration)
23+
24+ ## Git
25+
26+ - Branch: $(GitBranch)
27+ - Hash: $(GitCommitHash)
1928 </VersionText>
2029 </PropertyGroup>
2130
Original file line number Diff line number Diff line change @@ -13,9 +13,18 @@ $(Product)
1313
1414%(MyAssemblyIdentities.Version)
1515
16- ## Build At
16+ ## Build On
1717
18- $([System.DateTime]::Now.ToString("yyyy-MM-dd HH:mm:ss %K"))
18+ $([System.DateTime]::UtcNow.ToString("yyyy-MM-ddTHH:mm:ss"))
19+
20+ ## Build Configuration
21+
22+ $(Configuration)
23+
24+ ## Git
25+
26+ - Branch: $(GitBranch)
27+ - Hash: $(GitCommitHash)
1928 </VersionText>
2029 </PropertyGroup>
2130
Original file line number Diff line number Diff line change 11<Project>
22 <!-- Output assenbly version to text file for including on deploy by msbuild script. -->
33 <Target Name="GenerateVersionText" AfterTargets="Build">
4+ <GetAssemblyIdentity AssemblyFiles="$(TargetPath)">
5+ <Output TaskParameter="Assemblies" ItemName="MyAssemblyIdentities" />
6+ </GetAssemblyIdentity>
47 <PropertyGroup>
58 <VersionText>
69$(Product)
710==============================
811
9- ## Version
12+ ## Assembly Version
1013
11- $( Version)
14+ %(MyAssemblyIdentities. Version)
1215
13- ## Build At
16+ ## Build On
1417
15- $([System.DateTime]::Now.ToString("yyyy-MM-dd HH:mm:ss %K"))
18+ $([System.DateTime]::UtcNow.ToString("yyyy-MM-ddTHH:mm:ss"))
19+
20+ ## Build Configuration
21+
22+ $(Configuration)
1623 </VersionText>
1724 </PropertyGroup>
1825
You can’t perform that action at this time.
0 commit comments