mirror of
https://github.com/onyx-and-iris/voicemeeter-compact.git
synced 2025-01-18 04:10:46 +00:00
upd spec path
This commit is contained in:
parent
f459cdee44
commit
70c225bda3
21
build.ps1
21
build.ps1
@ -4,36 +4,37 @@ param(
|
|||||||
[string]$theme
|
[string]$theme
|
||||||
)
|
)
|
||||||
|
|
||||||
function Format-Path {
|
function Format-SpecName {
|
||||||
param($Kind)
|
param(
|
||||||
|
[string]$Kind
|
||||||
|
)
|
||||||
return @(
|
return @(
|
||||||
$prefix,
|
$prefix,
|
||||||
(& { if ($theme) { $theme } else { "" } }),
|
(& { if ($theme) { $theme } else { "" } }),
|
||||||
"${Kind}"
|
$Kind
|
||||||
).Where({ $_ -ne "" }) -Join "_"
|
).Where({ $_ -ne "" }) -Join "_"
|
||||||
}
|
}
|
||||||
|
|
||||||
function Compress-Builds {
|
function Compress-Builds {
|
||||||
$target = Join-Path -Path $PSScriptRoot -ChildPath "dist"
|
$target = Join-Path -Path $PSScriptRoot -ChildPath "dist"
|
||||||
@("basic", "banana", "potato") | ForEach-Object {
|
@("basic", "banana", "potato") | ForEach-Object {
|
||||||
$compress_path = Format-Path -Kind $_
|
$compressPath = Format-SpecName -Kind $_
|
||||||
Compress-Archive -Path $(Join-Path -Path $target -ChildPath $compress_path) -DestinationPath $(Join-Path -Path $target -ChildPath "${compress_path}.zip") -Force
|
Compress-Archive -Path (Join-Path -Path $target -ChildPath $compressPath) -DestinationPath (Join-Path -Path $target -ChildPath "${compressPath}.zip") -Force
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function Get-Builds {
|
function Get-Builds {
|
||||||
@("basic", "banana", "potato") | ForEach-Object {
|
@("basic", "banana", "potato") | ForEach-Object {
|
||||||
$spec_path = Format-Path -Kind $_
|
$specName = Format-SpecName -Kind $_
|
||||||
|
|
||||||
"building $spec_path" | Write-Host
|
Write-Host "building $specName"
|
||||||
|
|
||||||
poetry run pyinstaller "$spec_path.spec" --noconfirm
|
poetry run pyinstaller --noconfirm --distpath (Join-Path -Path "dist" -ChildPath $specName) (Join-Path -Path "spec" -ChildPath "${specName}.spec")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function main {
|
function main {
|
||||||
Get-Builds
|
Get-Builds
|
||||||
|
|
||||||
Compress-Builds
|
Compress-Builds
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user