File tree 1 file changed +42
-0
lines changed
1 file changed +42
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : Release Build
2
+
3
+ on :
4
+ push :
5
+ tags :
6
+ - ' v*'
7
+
8
+ jobs :
9
+ build :
10
+ runs-on : ubuntu-latest
11
+ name : Build & Publish to NuGet
12
+ environment : nuget
13
+ env :
14
+ solution-path : ' ./src/ICG AspnetCore Utilities.sln'
15
+ steps :
16
+ - uses : actions/checkout@v2
17
+ with :
18
+ fetch-depth : 0
19
+
20
+ - name : Ensure .NET Installed
21
+ uses : actions/setup-dotnet@v1
22
+ with :
23
+ dotnet-version : 5.0.x
24
+
25
+ - name : Install GitVersion
26
+ run : dotnet tool install --global GitVersion.Tool
27
+
28
+ - name : Determine Version
29
+ id : gitversion
30
+ uses :
gittools/actions/gitversion/[email protected]
31
+ with :
32
+ useConfigFile : true
33
+
34
+ - name : Restore Packages
35
+ run : dotnet restore "${{ env.solution-path }}"
36
+ - name : Build
37
+ run : dotnet build "${{ env.solution-path }}" --no-restore --configuration Release -p:version=${{ steps.gitversion.outputs.majorMinorPatch }}
38
+ - name : Test
39
+ run : dotnet test "${{ env.solution-path }}" --no-build --configuration Release
40
+
41
+ - name : Publish
42
+ run : nuget push **\*.nupkg -Source 'https://api.nuget.org/v3/index.json' -ApiKey ${{secrets.ICG_NUGET_API_KEY}}
You can’t perform that action at this time.
0 commit comments