Skip to content

Commit 67fcb76

Browse files
author
Jamil Maqdis Anton
committed
add publish to nuget workflow
1 parent e06128c commit 67fcb76

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: Publish to nuget
2+
3+
on:
4+
release:
5+
types: [created, edited]
6+
7+
jobs:
8+
publish:
9+
runs-on: ubuntu-latest
10+
11+
steps:
12+
- uses: actions/checkout@v2
13+
- name: Install dependencies
14+
run: dotnet restore
15+
- name: Build
16+
run: dotnet build --configuration Release --no-restore
17+
- name: Test
18+
run: dotnet test --no-restore --verbosity normal
19+
- name: Create the package
20+
run: dotnet pack --configuration Release -o Release -p:PackageVersion=${GITHUB_REF/refs\/tags\/v/''} --include-source
21+
- name: Publish the package to NuGet
22+
env:
23+
NUGET_AUTH_TOKEN: ${{secrets.SQLSTREAMSTORE_NUGET_AUTH_TOKEN}}
24+
run: dotnet nuget push Release/*.nupkg --skip-duplicate --no-symbols true --source https://api.nuget.org/v3/index.json -k ${NUGET_AUTH_TOKEN}

0 commit comments

Comments
 (0)