Skip to content

Commit

Permalink
Trying to look for weird characters.
Browse files Browse the repository at this point in the history
  • Loading branch information
brunchboy committed Feb 17, 2024
1 parent 0b1ed2b commit 6aab375
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions .github/scripts/build_msi.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,28 @@ copy ".\.github\resources\MSI Template.wxs" ".\"
& $Candle -dAppName=""$env:blt_name"" -dAppVersion=""$env:build_version"" -dAppVendor=""$env:blt_vendor"" -dAppUpgradeCode=""$env:blt_upgradecode"" -dAppDescription=""$env:blt_description"" -dAppVendorFolder=""$env:blt_vendor_folder"" -dAppIcon=""$env:blt_icon"" -nologo *.wxs -ext WixUIExtension -ext WixFirewallExtension -arch x64

#Compile MSI

function Printable([string] $s) {
$Matcher =
{
param($m)

$x = $m.Groups[0].Value
$c = [int]($x.ToCharArray())[0]
switch ($c)
{
9 { '\t' }
13 { '\r' }
10 { '\n' }
92 { '\\' }
Default { "\$c" }
}
}
return ([regex]'[^ -~\\]').Replace($s, $Matcher)
}

$CurrentWorkingDir = (Get-Location).Path
$LightOutFile = $CurrentWorkingDir+"\"+$env:artifact_name
Write-Output (Printable $LightOutFile)
Write-Output "Compile MSI: -out $LightOutFile"
& $Light -b "Beat Link Trigger" -nologo "*.wixobj" -out ""$LightOutFile"" -ext WixUIExtension -ext WixFirewallExtension

0 comments on commit 6aab375

Please sign in to comment.