Skip to content

Commit

Permalink
Make build deterministic (#148)
Browse files Browse the repository at this point in the history
Added validation of nuget package health to test build

Co-authored-by: Alex Davies <[email protected]>
  • Loading branch information
alex-davies and Alex Davies authored Apr 20, 2024
1 parent e3f33bf commit 72b8943
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,6 @@ jobs:
with:
dotnet-version: 8.0.*
- name: Pack
run: dotnet pack --output ./artifacts --configuration Release -p:GeneratePackageOnBuild=false -p:Version=$RELEASE_VERSION
run: dotnet pack --output ./artifacts --configuration Release -p:GeneratePackageOnBuild=false -p:ContinuousIntegrationBuild=true -p:Version=$RELEASE_VERSION
- name: Publish packages
run: dotnet nuget push ./artifacts/**.nupkg --source nuget.org --api-key ${{secrets.NUGET_TOKEN}}
10 changes: 8 additions & 2 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,15 @@ jobs:
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.0.*
- name: Install dotnet-validate
run: dotnet tool install --global dotnet-validate --version 0.0.1-preview.304
- name: Restore dependencies
run: dotnet restore
- name: Build
run: dotnet build --no-restore
run: dotnet build -p:ContinuousIntegrationBuild=true --configuration Release --no-restore
- name: Test
run: dotnet test --no-build --verbosity normal
run: dotnet test --configuration Release --no-build --verbosity normal
- name: Pack
run: dotnet pack --output ./artifacts --no-build
- name: Validate NuGet package
run: dotnet-validate package local artifacts/*.nupkg

0 comments on commit 72b8943

Please sign in to comment.