From 1ddc6cfdbcabee5d1339ddd8ddd2f7d8ed949c8c Mon Sep 17 00:00:00 2001 From: seven Date: Tue, 28 May 2024 02:06:04 +0800 Subject: [PATCH] feat: setup windows codesign Signed-off-by: seven --- .github/workflows/release.yml | 31 ++++++++++++++++---- package-lock.json | 4 +-- src/views/login/index.vue | 53 +++++++++++++++-------------------- 3 files changed, 50 insertions(+), 38 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 1a85ea8..b322c90 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -2,7 +2,7 @@ name: distributions release on: push: - branches: [master] + branches: [ master ] concurrency: group: ${{ github.workflow }}-${{ github.ref }} @@ -12,8 +12,8 @@ jobs: pre-release: strategy: matrix: - os: [macos-latest, ubuntu-latest, windows-latest] - node-version: [20.x] + os: [ macos-latest, ubuntu-latest, windows-latest ] + node-version: [ 20.x ] runs-on: ${{ matrix.os }} steps: @@ -30,15 +30,37 @@ jobs: - uses: actions/setup-python@v4 with: python-version: '3.10' + - name: Setup .NET Core SDK + if: matrix.os == 'windows-latest' + uses: actions/setup-dotnet@v2 + with: + dotnet-version: 6.0.x - run: npm ci - run: npm run package - name: Build app shell: bash run: ./scripts/make-distributions.sh + - name: Sign files with Trusted Signing + if: matrix.os == 'windows-latest' + uses: azure/trusted-signing-action@v0.3.19 + with: + azure-tenant-id: ${{ secrets.AZURE_TENANT_ID }} + azure-client-id: ${{ secrets.AZURE_CLIENT_ID }} + azure-client-secret: ${{ secrets.AZURE_CLIENT_SECRET }} + endpoint: https://eus.codesigning.azure.net/ + trusted-signing-account-name: vscx-codesigning + certificate-profile-name: vscx-certificate-profile + files-folder: ${{ github.workspace }}\out\make + files-folder-depth: 7 + files-folder-filter: exe + file-digest: SHA256 + timestamp-rfc3161: http://timestamp.acs.microsoft.com + timestamp-digest: SHA256 + - name: Upload artifacts uses: actions/upload-artifact@v4 with: - name: artifacts-${{ matrix.os }} + name: artifacts-${{ matrix.os }} path: out/make/* release: needs: pre-release @@ -71,7 +93,6 @@ jobs: ${{ steps.changelog.outputs.compareurl }} ${{ steps.changelog.outputs.changelog }} - - name: Release App uses: "marvinpinto/action-automatic-releases@latest" if: steps.tag_release.outputs.successful diff --git a/package-lock.json b/package-lock.json index 14a5bad..cef2e81 100644 --- a/package-lock.json +++ b/package-lock.json @@ -24,8 +24,8 @@ "pinia-plugin-persistedstate": "^3.2.1", "ulidx": "^2.3.0", "update-electron-app": "^3.0.0", - "vue": "^3.4.21", - "vue-i18n": "^9.10.1", + "vue": "^3.4.21", + "vue-i18n": "^9.10.1", "vue-router": "^4.2.5" }, "devDependencies": { diff --git a/src/views/login/index.vue b/src/views/login/index.vue index 95b7233..9feaefe 100644 --- a/src/views/login/index.vue +++ b/src/views/login/index.vue @@ -2,21 +2,13 @@