Skip to content

Commit

Permalink
Workflow to push to Nuget (#1)
Browse files Browse the repository at this point in the history
* Create nuget-deploy.yml

* Update workflow

* Update name

* Pack the nuget package

* Update working directory
  • Loading branch information
arunlalam authored Oct 25, 2024
1 parent 9c9a38d commit 7d062bb
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions .github/workflows/nuget-deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: Public package to NuGet
on:
push:
branches: [main]
jobs:
build:
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Pack nuget package
working-directory: ./src/Segment.PublicApi
run: dotnet pack -c Release
- name: Push nuget package
working-directory: ./src/Segment.PublicApi
run: dotnet nuget push bin/Release/Segment.PublicApi.*.nupkg -k ${NUGET_API_KEY} --source https://api.nuget.org/v3/index.json --skip-duplicate
env:
GITHUB_TOKEN: ${{ secrets.NUGET_API_KEY }}

0 comments on commit 7d062bb

Please sign in to comment.