Skip to content
Draft
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
51 changes: 51 additions & 0 deletions .github/workflows/PR.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@

name: Hearthis CI workflow

on:
pull_request:
branches: [ master ]

jobs:

build:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest]
runs-on: ${{ matrix.os }}

steps:
- name: Checkout
uses: actions/checkout@5a4ac90
with:
fetch-depth: 0

# Install the .NET Core workload
- name: Install .NET Core
uses: actions/setup-dotnet@51f6837
with:
dotnet-version: 5.0.x

# Add MSBuild to the PATH: https://github.com/microsoft/setup-msbuild
- name: Setup MSBuild.exe (Windows OS)
uses: microsoft/setup-msbuild@c26a08b
env:
ACTIONS_ALLOW_UNSECURE_COMMANDS: true # So the PATH can be set by this step
if: ${{ matrix.os == 'windows-latest' }}

# Run the unit tests
- name: Restore and Build
env:
ACTIONS_ALLOW_UNSECURE_COMMANDS: true # So gitversion can set environment vars during the build
run: msbuild build/build.proj /t:Build

- name: Test
if: success()
run: msbuild build/build.proj /t:Test

- name: Test Report
uses: MirrorNG/nunit-reporter@eba9570
if: always()
with:
path: output/**/TestResults.xml
access-token: ${{ secrets.GITHUB_TOKEN }}
50 changes: 50 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
name: CI Build

on:
push:
branches:
- '*'
- '!<default>'
- '!2.0'
pull_request:
branches:
- '*'

push:
branches:
- master
- '!2.0'
pull_request:
- '!2.0'
workflow_dispatch:

jobs:
build:
runs-on: windows-latest

steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Setup NuGet
uses: NuGet/setup-nuget@v2

- name: Restore NuGet packages
run: nuget restore HearThis.sln

- name: Build solution
run: msbuild HearThis.sln /t:Build /p:Configuration=Release /p:Platform=x64

- name: Run tests
run: |
mkdir output
nunit3-console.exe --result=output/TestResults.xml --noheader output/Release/*Tests.dll
env:
NUnitConsolePath: packages/NUnit.ConsoleRunner/tools

- name: Create release notes
run: |
ConvertReleaseNotesToHtml.exe --input DistFiles/ReleaseNotes.md --output output/ReleaseNotes.html

- name: Create download pointers
run: msbuild build/build.proj /t:MakeDownloadPointers
Loading