From 4576a5cc3bd29301b3e2b2ec85f2f87b46214832 Mon Sep 17 00:00:00 2001 From: Nickolas Gupton Date: Sat, 23 Nov 2024 03:19:58 -0600 Subject: [PATCH 1/2] Enable workflow on PR --- .github/workflows/main.yml | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 12264c9..d593490 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1,6 +1,10 @@ name: main -on: [push] +on: [push, pull_request] + +# Needed for .NET 9 support, as this is currently not included on ubuntu-latest +env: + DOTNET_VERSION: '9.0.x' jobs: build: @@ -11,6 +15,11 @@ jobs: with: fetch-depth: 0 + - name: Setup .NET + uses: actions/setup-dotnet@v4 + with: + dotnet-version: ${{ env.DOTNET_VERSION }} + - name: Build run: | dotnet restore dotnet-packaging.sln @@ -23,6 +32,7 @@ jobs: dotnet test Packaging.Targets.Tests/Packaging.Targets.Tests.csproj -l "trx;LogFileName=pkg/Packaging.Targets.Tests.trx" - uses: actions/upload-artifact@v4 + if: github.event_name != 'pull_request' with: name: pkg path: pkg/ From 44e3c67f972197ff04e0dff9661f774f525beb27 Mon Sep 17 00:00:00 2001 From: Nickolas Gupton Date: Fri, 20 Dec 2024 13:08:48 -0600 Subject: [PATCH 2/2] Add .NET 6 and 7 to pipeline --- .github/workflows/main.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index d593490..4167c8f 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -2,10 +2,6 @@ name: main on: [push, pull_request] -# Needed for .NET 9 support, as this is currently not included on ubuntu-latest -env: - DOTNET_VERSION: '9.0.x' - jobs: build: runs-on: ubuntu-latest @@ -18,7 +14,11 @@ jobs: - name: Setup .NET uses: actions/setup-dotnet@v4 with: - dotnet-version: ${{ env.DOTNET_VERSION }} + dotnet-version: | + 6.0.x + 7.0.x + 8.0.x + 9.0.x - name: Build run: |