Skip to content

Release to NuGet

Release to NuGet #6

Workflow file for this run

name: Release to NuGet
on:
release:
types: [published]
jobs:
build:
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 6.0.x
- name: Restore dependencies
run: dotnet restore ./SignalsDotnet
- name: Build
run: dotnet build -c Release ./SignalsDotnet --no-restore
- name: Test
run: dotnet test -c Release ./SignalsDotnet/SignalsDotnet.Tests --no-build --verbosity normal
- name: Pack nugets
run: dotnet pack SignalsDotnet/SignalsDotnet -c Release --no-build --output .
- name: Push to NuGet
run: dotnet nuget push "*.nupkg" --api-key ${{secrets.nuget_api_key}} --source https://api.nuget.org/v3/index.json