Skip to content

Publish to Nuget

Publish to Nuget #8

Workflow file for this run

name: Publish to Nuget
on:
workflow_dispatch:
inputs:
version:
required: true
type: string
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ windows-latest ]
steps:
- uses: actions/checkout@v2
- name: Setup .NET
uses: actions/setup-dotnet@v1
with:
dotnet-version: 7.x
- name: Pack
run: dotnet pack /p:Version=${{ inputs.version }} --output .
- name: Push
env:
NUGET_KEY: ${{ secrets.NUGET_API_KEY }}
run: dotnet nuget push innersloth.Hazel-Networking.${{ inputs.version }}.nupkg --source https://api.nuget.org/v3/index.json --api-key "$env:NUGET_KEY"