Skip to content

Commit

Permalink
CI tweaks to address race condition
Browse files Browse the repository at this point in the history
  • Loading branch information
drewcassidy committed Sep 21, 2024
1 parent b80b464 commit 3a2b12d
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 6 deletions.
11 changes: 11 additions & 0 deletions .github/workflows/internal-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ jobs:
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1
DOTNET_NOLOGO: true
runs-on: ubuntu-latest
outputs:
package-version: ${{ steps.get-version.outputs.version }}
steps:
- uses: actions/checkout@v4
with:
Expand All @@ -30,6 +32,13 @@ jobs:
with:
dotnet-version: 8.0.x

- name: Get Version
id: get-version
run: |
dotnet tool install --global minver-cli --version 5.0.0
minver
echo "version=$(minver -v e)" >> "$GITHUB_OUTPUT"
- name: Build
run: dotnet build KSPBuildTools.csproj

Expand All @@ -48,6 +57,8 @@ jobs:
test-plugin-nuget:
uses: './.github/workflows/internal-test-plugin-nuget.yml'
needs: [ build ]
with:
package-version: ${{ needs.build.outputs.package-version }}

test-plugin-legacy:
uses: './.github/workflows/internal-test-plugin-legacy.yml'
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/internal-test-plugin-nuget.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@ name: Test Plugin Mod (NuGet)

on:
workflow_call:
inputs:
package-version:
type: string
required: true

env:
TESTDIR: tests/plugin-mod-nuget
Expand All @@ -21,12 +25,6 @@ jobs:
with:
dotnet-version: 8.0.x

- name: Get Version
run: |
dotnet tool install --global minver-cli --version 5.0.0
minver
echo "KSPBuildToolsVersion=$(minver -v e)" >> "$GITHUB_ENV"
- name: Setup Nuget Package Sources
run: |
mkdir -p ${{ env.NuGetDirectory }}/local
Expand All @@ -44,6 +42,8 @@ jobs:
ksp-zip-url: https://github.com/KSPModdingLibs/KSPLibs/raw/main/KSP-1.12.5.zip
working-directory: ${{ env.TESTDIR }}
solution-file-path: plugin-mod.csproj
env:
KSPBuildToolsVersion: ${{ inputs.package-version }}

- uses: ./.github/actions/assemble-release
with:
Expand Down

0 comments on commit 3a2b12d

Please sign in to comment.