Merge pull request #1198 from nunit/dependabot/nuget/NUnit3TestAdapte… #16
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: NUnit3TestAdapter.Myget.Publish | |
on: | |
push: | |
branches: | |
- main | |
- master | |
- release | |
- 'v3' | |
- myget | |
workflow_dispatch: | |
defaults: | |
run: | |
shell: pwsh | |
jobs: | |
build-windows: | |
name: Windows Build | |
runs-on: windows-latest | |
steps: | |
- name: ⤵Checkout Source | |
uses: actions/[email protected] | |
- name: 🛠️ Setup .NET | |
uses: actions/setup-dotnet@v4 | |
with: | |
dotnet-version: | | |
3.1.x | |
5.0.x | |
6.0.x | |
7.0.x | |
8.0.x | |
- name: Build | |
run: .\build.ps1 -t QuickRelease | |
- name: 💾 Upload build artifacts | |
uses: actions/upload-artifact@v4 | |
with: | |
name: Package | |
path: package | |
- name: Publish nupkg and snupkg to Myget.org | |
run: | | |
foreach($file in (Get-ChildItem package -Recurse -Include *.nupkg)) { | |
dotnet nuget push $file --api-key "${{ secrets.PUBLISHMYGET }}" --source https://www.myget.org/F/nunit/api/v3/index.json --skip-duplicate | |
} | |
foreach($file in (Get-ChildItem "package" -Recurse -Include *.snupkg)) { | |
dotnet nuget push $file --api-key "${{ secrets.PUBLISHMYGET }}" --source https://www.myget.org/F/nunit/api/v3/index.json --skip-duplicate | |
} |