Skip to content

Nuget Publish

Nuget Publish #3

Workflow file for this run

name: Nuget Publish
on:
workflow_dispatch:
inputs:
version:
description: version
required: true
type: string
jobs:
publish-to-nuget:
runs-on: ubuntu-latest
steps:
- name: version pattern
id: check-version
run: |
version="${{ github.event.inputs.version }}"
if [[ $version =~ [0-9]+\.[0-9]+\.[0-9]+ ]]; then
echo "Input matches pattern: $version"
else
echo "Input does not match pattern: $version"
exit 1
fi
- name: version check
if: success()
run: echo ok
- name: Checkout
uses: actions/checkout@v3
- name: Setup Dotnet
uses: actions/setup-dotnet@v3
with:
dotnet-version: '7.x'
- name: restore dependencies
run: dotnet restore
- name: Build
run: dotnet build -C Release --no-restore
- name: Test
run: dotnet test -c Release --no-build --verbosity normal