From 59d8aaa70d91f13709cf60160584754c2dd42a32 Mon Sep 17 00:00:00 2001 From: Max Bechtold Date: Sun, 19 Jul 2020 11:46:56 +0200 Subject: [PATCH] #45 Port bundle script to Powershell Core --- .github/workflows/main.yml | 3 ++- resources/bundle-dr1.ps1 | 7 +++++++ 2 files changed, 9 insertions(+), 1 deletion(-) create mode 100644 resources/bundle-dr1.ps1 diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 9a7b7fb..b31b29f 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -69,7 +69,8 @@ jobs: - name: Bundle DR1 executable / PyInstaller run: | - resources\bundle-dr1.bat + resources\bundle-dr1.ps1 + shell: pwsh env: DRTR_CODESIGN_CERTIFICATE_PASS: ${{ secrets.DRTR_CODESIGN_CERTIFICATE_PASS }} diff --git a/resources/bundle-dr1.ps1 b/resources/bundle-dr1.ps1 new file mode 100644 index 0000000..869f285 --- /dev/null +++ b/resources/bundle-dr1.ps1 @@ -0,0 +1,7 @@ +if (Test-Path dirtrally-lb.db) { + Remove-Item -Force dirtrally-lb.db +} +bin\sqlite3 -batch -init resources\setup-dr1.sql dirtrally-lb.db .exit +pyinstaller timerecord.spec --noconfirm --name timerecorder-dr1 +pwsh.exe -wd resources resources\sign.ps1 -Exe ..\dist\timerecorder-dr1\timerecord.exe +exit $LASTEXITCODE \ No newline at end of file