File tree Expand file tree Collapse file tree 1 file changed +58
-0
lines changed
Expand file tree Collapse file tree 1 file changed +58
-0
lines changed Original file line number Diff line number Diff line change 1+ name : CD
2+
3+ on :
4+ workflow_dispatch :
5+ pull_request :
6+ branches :
7+ - main
8+
9+ jobs :
10+ build :
11+ runs-on : windows-latest
12+ environment : NuGet
13+ strategy :
14+ fail-fast : false
15+ matrix :
16+ configuration : [Release]
17+ platform : [Any CPU]
18+ env :
19+ WORKING_DIR : ${{ github.workspace }}
20+ SOLUTION_PATH : ' ${{ github.workspace }}\CubeKit.sln'
21+ HEAD_PROJECTS_DIR : ' ${{ github.workspace }}\src\platforms'
22+ HEAD_EXTENSIONS_DIR : ' ${{ github.workspace }}\src\extensions'
23+ CONFIGURATION : ${{ matrix.configuration }}
24+ ARCHITECTURE : ${{ matrix.platform }}
25+
26+ steps :
27+ - name : Checkout the repository
28+ uses : actions/checkout@v4
29+ - name : Setup MSBuild
30+ uses : microsoft/setup-msbuild@v2
31+ - name : Setup NuGet
32+ uses : NuGet/setup-nuget@v2
33+ - name : Setup .NET
34+ uses : actions/setup-dotnet@v4
35+ with :
36+ dotnet-version : 9.x
37+
38+ - name : Restore project
39+ shell : pwsh
40+ run : |
41+ msbuild $env:SOLUTION_PATH `
42+ -t:Restore `
43+ -p:Platform=$env:ARCHITECTURE `
44+ -p:Configuration=$env:CONFIGURATION
45+
46+ - name : Build CubeKit
47+ run : |
48+ msbuild "$env:SOLUTION_PATH" `
49+ -t:Build `
50+ -p:Platform=$env:PLATFORM `
51+ -p:Configuration=$env:CONFIGURATION
52+
53+ - name : Package CubeKit
54+ run : dotnet pack ${{ env.PACKAGE_PROJECT_PATH }} --configuration Release --no-build -o ./output
55+
56+ - name : Publish package to NuGet
57+ run : dotnet nuget push ./output/*.nupkg --api-key ${{ secrets.NUGET_API_KEY }} --source https://api.nuget.org/v3/index.json
58+ # TODO: Publish symbols as well
You can’t perform that action at this time.
0 commit comments