Skip to content

Commit

Permalink
Use MicaSetup to create .exe-type installer
Browse files Browse the repository at this point in the history
Check out how it works here: https://github.com/lemutec/MicaSetup
  • Loading branch information
emako committed Dec 15, 2024
1 parent dc67ab0 commit aa53627
Show file tree
Hide file tree
Showing 6 changed files with 61 additions and 1 deletion.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -293,3 +293,4 @@ __pycache__/
!/Build/AppxManifest.*
!/Build/assetslayout.resfiles
!/Build/priconfig.xml
!/Build/micasetup.json
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
43 changes: 43 additions & 0 deletions Build/micasetup.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
{
"Template": "${MicaDir}/template/default.7z",
"Package": "./QuickLook.7z",
"Output": "./${AppName}.exe",
"AppName": "QuickLook",
"KeyName": "QuickLook",
"ExeName": "QuickLook.exe",
"Publisher": "QL-Win",
"Version": "${Package}./${ExeName}|4",
"TargetFramework": "net472",
"Guid": "8B4A9CE5-67B5-4A94-81CB-3771F688FDEB",
"Favicon": "./Assets/Square44x44Logo.altform-unplated_targetsize-256.png",
"Icon": "./Assets/Square44x44Logo.altform-unplated_targetsize-256.setup.png",
"UnIcon": "./Assets/Square44x44Logo.altform-unplated_targetsize-256.uninst.png",
"LicenseFile": "../LICENSE-GPL.txt",
"License": null,
"LicenseType": null,
"RequestExecutionLevel": "admin",
"SingleInstanceMutex": null,
"IsCreateDesktopShortcut": true,
"IsCreateUninst": true,
"IsCreateStartMenu": true,
"IsPinToStartMenu": false,
"IsCreateQuickLaunch": true,
"IsCreateRegistryKeys": true,
"IsCreateAsAutoRun": false,
"IsCustomizeVisiableAutoRun": false,
"AutoRunLaunchCommand": "/autostart",
"IsUseFolderPickerPreferClassic": false,
"IsUseInstallPathPreferX86": false,
"IsUseRegistryPreferX86": null,
"IsAllowFullFolderSecurity": true,
"IsAllowFirewall": true,
"IsRefreshExplorer": true,
"IsInstallCertificate": false,
"IsEnableUninstallDelayUntilReboot": true,
"IsEnvironmentVariable": false,
"OverlayInstallRemoveExt": "exe,dll,pdb,config,winmd,txt,bat,ax,manifest,xshd",
"UnpackingPassword": null,
"MessageOfPage1": null,
"MessageOfPage2": null,
"MessageOfPage3": null
}
2 changes: 1 addition & 1 deletion QuickLook.Installer/Product.wxs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
<Product Id="*" Name="QuickLook" Language="1033"
Version="!(bind.FileVersion.fil22F7B7F07E63622AD2451459086A3CF2)" Manufacturer="Paddy Xu"
Version="!(bind.FileVersion.fil22F7B7F07E63622AD2451459086A3CF2)" Manufacturer="QL-Win"
UpgradeCode="c83b9c02-87d6-494e-9f5f-cf4c3900a54d">
<Package InstallerVersion="500" Compressed="yes" Platform="x86" InstallScope="perUser" />

Expand Down
16 changes: 16 additions & 0 deletions Scripts/pack-setup.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
Set-Location ../Build

Remove-Item .\QuickLook.7z -ErrorAction SilentlyContinue
7z a QuickLook.7z .\Package\* -t7z -mx=5 -mf=BCJ2 -r -y
makemica micasetup.json

Write-Output "This file makes QuickLook portable." >> .\Package\portable.lock
7z a QuickLook.7z .\Package\portable.lock -t7z -mx=5 -mf=BCJ2 -r -y

$version = git describe --always --tags --exclude latest
Remove-Item .\QuickLook-$version.7z -ErrorAction SilentlyContinue
Rename-Item .\QuickLook.7z QuickLook-$version.7z
Remove-Item .\QuickLook-$version.exe -ErrorAction SilentlyContinue
Rename-Item .\QuickLook.exe QuickLook-$version.exe

pause

0 comments on commit aa53627

Please sign in to comment.