From 5a24a4f3af0580a6433715a26b7652fc2901577e Mon Sep 17 00:00:00 2001 From: Morten Nielsen <1378165+dotMorten@users.noreply.github.com> Date: Wed, 22 Dec 2021 19:59:07 -0800 Subject: [PATCH] Update publish_nuget.yml --- .github/workflows/publish_nuget.yml | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/.github/workflows/publish_nuget.yml b/.github/workflows/publish_nuget.yml index a7ce57a..2f30b45 100644 --- a/.github/workflows/publish_nuget.yml +++ b/.github/workflows/publish_nuget.yml @@ -14,8 +14,17 @@ jobs: - name: Setup Visual Studio Command Prompt uses: microsoft/setup-msbuild@v1.0.2 + + - name: Get certificate + id: cert_file + uses: timheuer/base64-to-file@master + with: + fileName: 'certfile.pfx' + encodedString: ${{ secrets.BASE64_ENCODED_PFX }} - name: Build run: | - msbuild /restore /t:Build src/NmeaParser/NmeaParser.csproj /p:Configuration=Release + msbuild /restore /t:Build src/NmeaParser/NmeaParser.csproj /p:Configuration=Release /p:CertificatePath=${{ steps.cert_file.outputs.filePath }} /p:CertificatePassword=${{ secrets.PFX_PASSWORD }} + - name: Sign NuGet Package + run: nuget sign artifacts\NuGet\Release\*.nupkg -CertificatePath ${{ steps.cert_file.outputs.filePath }} -CertificatePassword ${{ secrets.PFX_PASSWORD }} -Timestamper http://timestamp.digicert.com –NonInteractive