Pack and Publish Nuget to Nuget.org #6
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Pack and Publish to Nuget.org | |
on: workflow_dispatch | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
env: | |
PROJECT_FILE_PATH: '/home/runner/work/tubular-dotnet/tubular-dotnet/src/Unosquare.Tubular/Unosquare.Tubular.csproj' | |
BUILD_PATH: '/home/runner/work/tubular-dotnet/tubular-dotnet/src/Unosquare.Tubular/bin/Release/*.nupkg' | |
steps: | |
- name: 🚕 Checkout codebase | |
uses: actions/checkout@v4 | |
- name: 🐜 Setup .NET | |
uses: actions/setup-dotnet@v4 | |
with: | |
dotnet-version: | | |
9.x | |
- name: 🏗 Build, Pack and Publish to Nuget.org | |
run: | | |
dotnet pack ${{ env.PROJECT_FILE_PATH }} --configuration Release -p:IncludeSymbols=true -p:SymbolPackageFormat=snupkg | |
dotnet nuget push ${{ env.BUILD_PATH }} --source https://api.nuget.org/v3/index.json --api-key ${{ secrets.NUGET_API_KEY }} |