From 7b13d09f591b708c5919310078332560f9c75677 Mon Sep 17 00:00:00 2001 From: Philippe Matray Date: Sat, 28 Feb 2026 15:03:37 +0100 Subject: [PATCH] fix: add build step before NuGet pack in CI workflow The pack step fails because staticwebassets.build.json manifest is not found. Adding an explicit dotnet build step before dotnet pack ensures the manifest is generated. The pack step now uses --no-build to avoid double-building. --- .github/workflows/main.yml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 011ffc0..14949f4 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -64,8 +64,13 @@ jobs: with: dotnet-version: 10.x + # Build the project first so that staticwebassets.build.json manifest is generated + - name: Build + run: dotnet build --configuration Release --no-restore + # Create the NuGet package in the folder from the environment variable NuGetDirectory - - run: dotnet pack --configuration Release --output ${{ env.NuGetDirectory }} + - name: Create NuGet package + run: dotnet pack --configuration Release --no-build --output ${{ env.NuGetDirectory }} # Publish the NuGet package as an artifact, so they can be used in the following jobs - uses: actions/upload-artifact@v7