1
0
mirror of synced 2024-07-01 03:27:40 +00:00
MassiveKnob/Windows/BuildRelease.ps1
Mark van Renswoude cae557e7e1 Implemented default device switching
Added VoiceMeeter plugin (run macro and get status)
Added Inno Setup script
Added Fusion 360 files for housing designs
2021-03-06 10:53:38 +01:00

41 lines
1.0 KiB
PowerShell

# Run this script from the Developer PowerShell found in Visual Studio 2019
# or the start menu to get the correct msbuild version on the path
#
# GitVersion is also required and must be available on the path
# Inno Setup 5 is used to compile the setup, it's path is specified below
#
$innoSetupCompiler = "C:\Program Files (x86)\Inno Setup 5\ISCC.exe"
$versionJson = & GitVersion | Out-String
try
{
$version = ConvertFrom-Json $versionJson
}
catch
{
Write-Host "Error while parsing GitVersion output: $($_.Exception.Message)" -ForegroundColor Red
Write-Host $versionJson -ForegroundColor Gray
exit 1
}
Write-Host "GitVersion: $($version.LegacySemVer)"
$env:BUILD_VERSION = $version.LegacySemVer
& msbuild MassiveKnob.sln /t:Clean /t:Build /p:Configuration=Release
if (!$?)
{
Write-Host "MSBuild failed, aborting..." -ForegroundColor Red
exit 1
}
& $innoSetupCompiler "Setup\MassiveKnobSetup.iss"
if (!$?)
{
Write-Host "Inno Setup failed, aborting..." -ForegroundColor Red
exit 1
}