From 795ffe20a310eb4ae6d275934ddded5fc733ce10 Mon Sep 17 00:00:00 2001 From: Prateek Sunal Date: Wed, 14 Feb 2024 19:11:32 +0530 Subject: [PATCH] fix: signing --- .github/workflows/desktop.yml | 25 ++++++++++--------------- 1 file changed, 10 insertions(+), 15 deletions(-) diff --git a/.github/workflows/desktop.yml b/.github/workflows/desktop.yml index 94e3835810..94411f799f 100644 --- a/.github/workflows/desktop.yml +++ b/.github/workflows/desktop.yml @@ -165,13 +165,6 @@ jobs: # Fetch sub modules - run: git submodule update --init --recursive - - name: Create PFX - id: create_pfx - uses: timheuer/base64-to-file@v1 - with: - fileName: "certificate.pfx" - encodedString: ${{ secrets.WINDOWS_CERTIFICATE }} - - name: Build Flutter app run: | flutter config --enable-windows-desktop @@ -183,15 +176,17 @@ jobs: - name: Copy Windows release files run: cp -r build/windows/x64/runner/Release auth-windows-exe - - name: Sign Windows - env: - CERTIFICATE_PASSWORD: ${{ secrets.WINDOWS_CERTIFICATE_PASSWORD }} - PFX_PATH: ${{ steps.create_pfx.outputs.filePath }} - run: | - SignTool sign /tr http://timestamp.digicert.com /td sha256 /fd sha256 /f "$PFX_PATH" /p $CERTIFICATE_PASSWORD "auth-windows-exe/enteauth.exe" - SignTool sign /tr http://timestamp.digicert.com /td sha256 /fd sha256 /f "$PFX_PATH" /p $CERTIFICATE_PASSWORD "$APP_NAME.exe" + - name: Code Sign Windows + uses: dlemstra/code-sign-action@master + with: + certificate: "${{ secrets.WINDOWS_CERTIFICATE }}" + password: "${{ secrets.WINDOWS_CERTIFICATE_PASSWORD }}" + files: | + auth-windows-exe/enteauth.exe + $APP_NAME.exe - - run: tar.exe -a -c -f auth-windows-${{ github.event_name == 'release' && github.event.release.tag_name || 'nightly' }}.zip auth-windows-exe + - name: Prepare Zip Windows + run: tar.exe -a -c -f auth-windows-${{ github.event_name == 'release' && github.event.release.tag_name || 'nightly' }}.zip auth-windows-exe - uses: svenstaro/upload-release-action@latest with: