From a7a921cc35020fc13d534173bf9f06ab1b626b9c Mon Sep 17 00:00:00 2001 From: mvadu <8618235+mvadu@users.noreply.github.com> Date: Fri, 27 Feb 2026 17:55:22 -0500 Subject: [PATCH] Fix NuGet pack and push - specify project path and handle wildcards properly --- .github/workflows/build.yml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 2935f4d..cd5df94 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -35,7 +35,7 @@ jobs: run: dotnet test --configuration ${{ env.CONFIGURATION }} --no-build --verbosity normal --filter "TestCategory=AppVeyor" - name: Pack NuGet packages - run: dotnet pack --configuration ${{ env.CONFIGURATION }} --no-build --output ./artifacts + run: dotnet pack src/AdysTech.CredentialManager/AdysTech.CredentialManager.csproj --configuration ${{ env.CONFIGURATION }} --no-build --output ./artifacts - name: Upload artifacts uses: actions/upload-artifact@v4 @@ -51,6 +51,11 @@ jobs: - name: Publish to NuGet if: github.event_name == 'push' && github.ref == 'refs/heads/master' - run: dotnet nuget push ./artifacts/*.nupkg --api-key ${{ secrets.NUGET_API_KEY }} --source https://api.nuget.org/v3/index.json --skip-duplicate + shell: pwsh + run: | + $packages = Get-ChildItem -Path ./artifacts -Filter *.nupkg + foreach ($package in $packages) { + dotnet nuget push $package.FullName --api-key ${{ secrets.NUGET_API_KEY }} --source https://api.nuget.org/v3/index.json --skip-duplicate + } env: NUGET_API_KEY: ${{ secrets.NUGET_API_KEY }}