nvda-addon-voicemeeter/build.ps1

25 lines
566 B
PowerShell
Raw Permalink Normal View History

2023-09-23 22:55:58 +01:00
param(
[switch]$build
)
function Copy-FilestoScratchpad {
$source = Join-Path $PSScriptRoot "addon" "globalPlugins" "voicemeeter"
2023-09-27 14:46:37 +01:00
$target = Join-Path $env:appdata "nvda" "scratchpad" "globalPlugins" "voicemeeter"
Robocopy $source $target | Out-Null
2023-09-23 22:55:58 +01:00
}
function main {
"Copying files to Scratchpad" | Write-Host
Copy-FilestoScratchpad
if ($build) {
Invoke-Expression ".venv/Scripts/Activate.ps1"
"Building add-on" | Write-Host
scons
deactivate
}
}
if ($MyInvocation.InvocationName -ne '.') { main }