File tree Expand file tree Collapse file tree 1 file changed +45
-0
lines changed
Expand file tree Collapse file tree 1 file changed +45
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Publish
2+
3+ on :
4+ push :
5+ branches : [ "master" ]
6+ tags : ['*']
7+ pull_request :
8+
9+ jobs :
10+ generate-version :
11+ runs-on : ubuntu-latest
12+ permissions :
13+ contents : write
14+ steps :
15+ - uses : actions/checkout@v2
16+
17+ - name : GitHub Tag Bump
18+ id : tab_bump
19+ uses :
anothrNick/[email protected] 20+ env :
21+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
22+ INITIAL_VERSION : 1.0.0
23+ DEFAULT_BUMP : patch
24+
25+ package-and-publish-lib :
26+ runs-on : ubuntu-latest
27+ steps :
28+ - uses : actions/checkout@v2
29+
30+ - name : Setup .NET Core
31+ uses : actions/setup-dotnet@v1
32+ with :
33+ dotnet-version : 8.0.x
34+
35+ - name : Generate NuGet package
36+ run : |
37+ dotnet pack \
38+ --configuration Release \
39+ -p:PackageVersion=${{ needs.generate-version.outputs.new_version }} \
40+ -o packages
41+
42+ - name : Publish NuGet package
43+ run : dotnet nuget push packages/*.nupkg \
44+ --api-key ${{ secrets.NUGET_API_KEY }} \
45+ --source https://api.nuget.org/v3/index.json
You can’t perform that action at this time.
0 commit comments