diff --git a/Scripts/post_build.ps1 b/Scripts/post_build.ps1 index ce9944624..093f92768 100644 --- a/Scripts/post_build.ps1 +++ b/Scripts/post_build.ps1 @@ -47,10 +47,20 @@ function Delete-Unused ($path, $config) { Remove-Item -Path $target -Include "*.xml" -Recurse } +function Remove-CreateDumpExe ($path, $config) { + $target = "$path\Output\$config" + + $depjson = Get-Content $target\Flow.Launcher.deps.json -raw + $depjson -replace '(?s)(.createdump.exe": {.*?}.*?\n)\s*', "" | Out-File $target\Flow.Launcher.deps.json -Encoding UTF8 + Remove-Item -Path $target -Include "*createdump.exe" -Recurse +} + + function Validate-Directory ($output) { New-Item $output -ItemType Directory -Force } + function Pack-Squirrel-Installer ($path, $version, $output) { # msbuild based installer generation is not working in appveyor, not sure why Write-Host "Begin pack squirrel installer" @@ -108,10 +118,12 @@ function Main { Publish-Self-Contained $p + Remove-CreateDumpExe $p $config + $o = "$p\Output\Packages" Validate-Directory $o Pack-Squirrel-Installer $p $v $o } } -Main \ No newline at end of file +Main