Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions .config/dotnet-tools.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,13 @@
],
"rollForward": false
},
"gitreleasemanager.tool": {
"version": "0.20.0",
"commands": [
"dotnet-gitreleasemanager"
],
"rollForward": false
},
"minver-cli": {
"version": "8.0.0",
"commands": [
Expand Down
66 changes: 66 additions & 0 deletions .github/workflows/Release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
name: Release
run-name: Release ${{ github.ref_name }}

# Pushing a tag releases that version. Push the new tag alone, with
# `git push origin <tag>`: `git push --tags` starts a release for every local tag
# that isn't on GitHub yet.
#
# The recipe's CheckRelease task stops the run before anything is pushed unless
# the tagged commit is on main, the tag is a public release version (stable, or a
# non-fractional beta or rc), the keys are present and a milestone named for the
# version holds only closed issues.

on:
push:
tags:
- '*'

concurrency:
group: release-${{ github.ref }}
cancel-in-progress: false

env:
DOTNET_NOLOGO: true # Disable the .NET logo
DOTNET_CLI_TELEMETRY_OPTOUT: true # Disable sending .NET CLI telemetry

jobs:
Release:
name: Release
runs-on: windows-latest

env:
MYGET_API_KEY: ${{ secrets.PUBLISH_MYGET_ORG }}
NUGET_API_KEY: ${{ secrets.PUBLISH_NUGET_ORG }}
CHOCO_API_KEY: ${{ secrets.PUBLISH_CHOCOLATEY_ORG }}
GITHUB_ACCESS_TOKEN: ${{ secrets.GH_ACCESS_CP }}

steps:
# A full fetch includes origin/main, which CheckRelease needs to find the tagged commit.
- name: ⤵️ Checkout Source
uses: actions/checkout@v7
with:
fetch-depth: 0

- name: 🛠️ Setup .NET
uses: actions/setup-dotnet@v6
with:
dotnet-version: |
8.0.x
9.0.x
10.0.x

- name: 🛠️ Install dotnet tools
run: dotnet tool restore

- name: 🧪 Check Release Tool Startup
run: dotnet tool run dotnet-gitreleasemanager -- showconfig --no-logo

- name: 🚀 Release
run: dotnet cake --target=Release --configuration=Release

- name: 💾 Upload Packages
if: always()
uses: actions/upload-artifact@v7
with:
name: Packages
path: packages
1 change: 1 addition & 0 deletions NUnit.Engine.Api.slnx
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
<Folder Name="/Solution Items/.github/" />
<Folder Name="/Solution Items/.github/Workflows/">
<File Path=".github/workflows/NUnit.Engine.Api.CI.yml" />
<File Path=".github/workflows/Release.yml" />
</Folder>
<Project Path="src/NUnit.Engine.Api.Tests/NUnit.Engine.Api.Tests.csproj" />
<Project Path="src/NUnit.Engine.Api/NUnit.Engine.Api.csproj" />
Expand Down
2 changes: 1 addition & 1 deletion build.cake
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// Load the recipe
#load nuget:?package=NUnit.Cake.Recipe&version=2.0.0-beta.5
#load nuget:?package=NUnit.Cake.Recipe&version=2.0.0-beta.6
// Comment out above line and uncomment below for local tests of recipe changes
//#load ../NUnit.Cake.Recipe/recipe/*.cake

Expand Down