Files
proxy-god/scripts/setup_and_build.ps1
Dr Jones 08683ab328
Some checks failed
CI / Test Python 3.10 (push) Has been cancelled
CI / Test Python 3.11 (push) Has been cancelled
CI / Test Python 3.12 (push) Has been cancelled
build: production Windows release pipeline (PyInstaller, SBOM, CI, signing hook)
2026-05-22 20:05:00 -07:00

49 lines
1.5 KiB
PowerShell

#Requires -Version 5.1
<#
.SYNOPSIS
Developer build: deps, tests (optional), PyInstaller, copy to Desktop, shortcut.
.DESCRIPTION
Lighter than release_build.ps1 — skips SBOM/zip/manifest. For daily dev iteration.
Production releases: use scripts\release_build.ps1 or build_release.bat
.PARAMETER SkipTests
Skip unittest gate (faster iteration).
#>
[CmdletBinding()]
param([switch]$SkipTests)
$ErrorActionPreference = "Stop"
. "$PSScriptRoot\_build_common.ps1"
$root = Get-RepoRoot
Set-Location $root
$py = Resolve-PythonExe
Write-Host "Using: $py"
& $py -c "import sys; assert sys.version_info >= (3, 10); print(sys.version)"
$ver = Get-ReleaseVersion
Install-BuildDependencies -PythonExe $py -Root $root
if (-not $SkipTests) {
Invoke-UnitTests -PythonExe $py -Root $root
}
Invoke-StageBundledGost -Root $root
Invoke-GenerateVersionInfo -PythonExe $py -Root $root -Version $ver -Commit (Get-GitCommit)
$exe = Invoke-PyInstallerBuild -PythonExe $py -Root $root
$hashInfo = Write-ExeHashSidecar -ExePath $exe
$desk = [Environment]::GetFolderPath("Desktop")
$deskExe = Join-Path $desk "ProxyChainManager.exe"
Copy-Item -LiteralPath $exe -Destination $deskExe -Force
Copy-Item -LiteralPath $hashInfo.Sidecar -Destination "$deskExe.sha256" -Force
Write-Host "Copied: $deskExe (+ .sha256)"
Write-Host "`n== Desktop shortcut =="
& powershell -NoProfile -ExecutionPolicy Bypass -File (Join-Path $root "scripts\create_desktop_shortcut.ps1")
Write-Host "`nDone. Launch from Desktop: Proxy God.lnk (or ProxyChainManager.exe)"