Skip to content

Windows x64 Build

Windows x64 Build #7

Workflow file for this run

# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions
name: Windows x64 Build
on:
release:
types: [created]
workflow_dispatch:
jobs:
build:
runs-on: windows-latest
strategy:
matrix:
node-version: [20]
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Retrieve the secret and write it to a file
shell: pwsh
env:
SECRET_FILE: ${{ secrets.SECRET_FILE }}
run: |
$env:SECRET_FILE | Out-File .\src\secrets.json
dir .\src
- name: Retrieve the settings and write them to a file
shell: pwsh
env:
SETTINGS_FILE: ${{ secrets.SETTINGS_FILE }}
run: |
$env:SETTINGS_FILE | Out-File .\config\settings.json
dir .\config
- name: Generate certificate file from secret
shell: pwsh
env:
SETTINGS_FILE: ${{ secrets.CERT_WINDOWS }}
run: |
$encodedBytes = [System.Convert]::FromBase64String("${{ secrets.CERT_WINDOWS }}");
Set-Content .\certs\installer.pfx -Value $encodedBytes -AsByteStream;
dir .\certs
# $pfx_cert_byte = [System.Convert]::FromBase64String()
# $currentDirectory = Get-Location
# $certificatePath = Join-Path -Path $currentDirectory -ChildPath $env:Wap_Project_Directory -AdditionalChildPath $env:SigningCertificate
# [IO.File]::WriteAllBytes("$certificatePath", $pfx_cert_byte)