[skip ci] cleanup

This commit is contained in:
Armin Schrenk
2025-05-08 11:07:37 +02:00
parent 8322633b14
commit 119d18d699
2 changed files with 19 additions and 6 deletions

14
dist/win/build.ps1 vendored
View File

@@ -18,12 +18,12 @@ $ProgressPreference = 'SilentlyContinue' # disables Invoke-WebRequest's progress
# check preconditions
if ((Get-Command "git" -ErrorAction SilentlyContinue) -eq $null)
{
Write-Host "Unable to find git.exe in your PATH (try: choco install git)"
Write-Error "Unable to find git.exe in your PATH (try: choco install git)"
exit 1
}
if ((Get-Command "mvn" -ErrorAction SilentlyContinue) -eq $null)
{
Write-Host "Unable to find mvn.cmd in your PATH (try: choco install maven)"
Write-Error "Unable to find mvn.cmd in your PATH (try: choco install maven)"
exit 1
}
if ((Get-Command 'wix' -ErrorAction SilentlyContinue) -eq $null)
@@ -104,7 +104,7 @@ if ((& "$Env:JAVA_HOME\bin\jlink" --help | Select-String -Pattern "Linking from
--no-header-files `
--no-man-pages `
--strip-debug `
--compress "zip-0" #do not compress to have improved msi compression
--compress "zip-0" #do not compress and use msi compression
$appPath = ".\$AppName"
if ($clean -and (Test-Path -Path $appPath)) {
@@ -190,6 +190,12 @@ $Env:JP_WIXHELPER_DIR = "."
--about-url $AboutUrl `
--file-associations resources/FAvaultFile.properties
if ($LASTEXITCODE -ne 0) {
Write-Error "jpackage MSI failed with exit code $LASTEXITCODE"
return 1;
}
#Create RTF license for bundle
&mvn -B -f $buildDir/../../pom.xml license:add-third-party "-Djavafx.platform=win" `
"-Dlicense.thirdPartyFilename=license.rtf" `
@@ -211,7 +217,7 @@ Write-Output "Downloading ${winfspUninstaller}..."
Invoke-WebRequest $winfspUninstaller -OutFile ".\bundle\resources\winfsp-uninstaller.exe" # redirects are followed by default
# copy MSI to bundle resources
Copy-Item ".\installer\$AppName-*.msi" -Destination ".\bundle\resources\$AppName.msi"
Copy-Item ".\installer\$AppName-*.msi" -Destination ".\bundle\resources\$AppName.msi" -Force
# create bundle including winfsp
& wix build `

View File

@@ -1,12 +1,19 @@
<!-- For Built in variables, see https://wixtoolset.org/docs/tools/burn/builtin-variables/-->
<ns0:Wix xmlns:ns0="http://wixtoolset.org/schemas/v4/wxs" xmlns:bal="http://wixtoolset.org/schemas/v4/wxs/bal" xmlns:util="http://wixtoolset.org/schemas/v4/wxs/util">
<ns0:Bundle Name="$(var.BundleName)" UpgradeCode="29eea626-2e5b-4449-b5f8-4602925ddf7b" Version="$(var.BundleVersion)" Manufacturer="$(var.BundleVendor)" AboutUrl="$(var.AboutUrl)" HelpUrl="$(var.HelpUrl)" UpdateUrl="$(var.UpdateUrl)" Copyright="$(var.BundleCopyright)" IconSourceFile="bundle\resources\Cryptomator.ico">
<ns0:Bundle Name="$(var.BundleName)"
UpgradeCode="29eea626-2e5b-4449-b5f8-4602925ddf7b"
Version="$(var.BundleVersion)"
Manufacturer="$(var.BundleVendor)"
AboutUrl="$(var.AboutUrl)"
HelpUrl="$(var.HelpUrl)"
UpdateUrl="$(var.UpdateUrl)"
Copyright="$(var.BundleCopyright)"
IconSourceFile="bundle\resources\Cryptomator.ico">
<!-- detect outdated WinFsp installations -->
<util:ProductSearch Variable="InstalledLegacyWinFspVersion" Result="version" UpgradeCode="82F812D9-4083-4EF1-8BC8-0F1EDA05B46B" />
<ns0:BootstrapperApplication>
<!-- Possible Attributes: LaunchTarget -->
<bal:WixStandardBootstrapperApplication LicenseFile="bundle\resources\license.rtf" ShowVersion="yes"
SuppressOptionsUI="yes"
Theme="rtfLargeLicense"