Skip to content

Commit

Permalink
Updated CI to publish on tag
Browse files Browse the repository at this point in the history
  • Loading branch information
jamesmcroft authored Oct 20, 2021
1 parent 515504f commit 8a4ac33
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
name: CI

on:
create:
branches:
- release/**
push:
tags:
- v*
branches:
- main
paths:
Expand Down Expand Up @@ -72,5 +71,5 @@ jobs:
run: dotnet test /p:Configuration=$env:BUILD_CONFIG /p:CollectCoverage=true /p:CoverletOutputFormat=cobertura --no-restore --no-build --verbosity normal

- name: Publish
if: startsWith(github.ref, 'refs/heads/release')
if: startsWith(github.ref, 'refs/tags/v')
run: nuget push **\*.nupkg -Source 'https://api.nuget.org/v3/index.json' -ApiKey ${{secrets.NUGET_API_KEY}}

0 comments on commit 8a4ac33

Please sign in to comment.