File tree Expand file tree Collapse file tree 2 files changed +42
-34
lines changed
Expand file tree Collapse file tree 2 files changed +42
-34
lines changed Original file line number Diff line number Diff line change 1+ name : publish nuget
2+
3+ on :
4+ push :
5+ tags :
6+ - ' *'
7+
8+ jobs :
9+ build :
10+
11+ runs-on : windows-latest
12+
13+ steps :
14+ - uses : actions/checkout@v1
15+
16+ - name : Setup .NET Core
17+ uses : actions/setup-dotnet@v1
18+ with :
19+ dotnet-version : 3.1.300
20+
21+ - name : Install dotnet tool
22+ run : dotnet tool install -g dotnetCampus.TagToVersion
23+
24+ - name : Set tag to version
25+ run : dotnet TagToVersion -t ${{ github.ref }}
26+
27+ - name : Build with dotnet
28+ run : dotnet build --configuration Release
29+
30+ - name : Install Nuget
31+ uses : nuget/setup-nuget@v1
32+ with :
33+ nuget-version : ' 5.x'
34+
35+ - name : Add private GitHub registry to NuGet
36+ run : |
37+ nuget sources add -name github -Source https://nuget.pkg.github.com/dotnet-campus/index.json -Username dotnet-campus -Password ${{ secrets.GITHUB_TOKEN }}
38+
39+ - name : Push generated package to GitHub registry
40+ run : |
41+ nuget push .\bin\Release\*.nupkg -Source github -SkipDuplicate
42+ nuget push .\bin\Release\*.nupkg -Source https://api.nuget.org/v3/index.json -SkipDuplicate -ApiKey ${{ secrets.NugetKey }} -NoSymbols
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments