Publish dotnet tool #19
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: Publish dotnet tool | |
# Basics from https://docs.microsoft.com/en-us/azure/dev-spaces/how-to/github-actions | |
on: | |
workflow_dispatch: | |
workflow_run: | |
workflows: ['Tests'] | |
types: [completed] | |
branches: | |
- main | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
if: ${{ github.event.workflow_run.conclusion == 'success' }} | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-dotnet@v3 | |
with: | |
dotnet-version: '8' | |
# Note that we need to pack twice because of an issue with staticwebassets. | |
- name: Build and Publish | |
run: | | |
dotnet restore | |
dotnet pack -c Release ./src/fhir-candle/fhir-candle.csproj | |
rm ./nupkg/*.nupkg | |
dotnet pack -c Release ./src/fhir-candle/fhir-candle.csproj | |
dotnet nuget push ./nupkg/*.nupkg --api-key ${{ secrets.GINOC_NUGET }} --source https://api.nuget.org/v3/index.json |