Skip to content

NuGet Publish

NuGet Publish #232

Workflow file for this run

name: NuGet Publish
on:
workflow_dispatch:
jobs:
setup:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Setup .NET
uses: actions/setup-dotnet@v2
with:
dotnet-version: 8.0.x
- name: Setup NodeJS
uses: actions/setup-node@v3.4.1
- name: Restore NuGet packages
run: |
dotnet restore
nuget-push:
runs-on: ubuntu-latest
needs: setup
strategy:
matrix:
project:
- src/Commons
- src/Core
- src/Web
- src/WebApi
- src/Plugins/Hangfire
- src/Plugins/Pdf
steps:
- uses: actions/checkout@v2
- name: Build and publish NuGet package
run: |
npm install --prefix src/Web
cd ${{ matrix.project }}
dotnet build -c release
dotnet pack -c release --output="nuget"
cd nuget
dotnet nuget push "*.nupkg" --api-key ${{ secrets.NUGET_API_KEY }} --source https://api.nuget.org/v3/index.json --skip-duplicate