Adding true MSI support
This is a major update to the msi files that Velopack can create for Windows.
This is a breaking change for the vpk CLI. The only MSI deployment tool is replaced with this new --msi option.
There is a sample branch under kdb/msi-example showing the usage with the Avalonia sample application. The updates are under the dev-scripts.
Unlike the previous MSI deployment tool that was modeled after the Clowd.Squirrel (and parent Squirrel project) that just injects a registry key to run on the startup of each user and perform a per-user install, this MSI is a true installer that can be used as a replacement for the Setup.exe.
The MSI currently has the following behavior:
- It will always display a UI
- It leverages the previous
--msiVersionOverride <Version>option to allow setting the MSI version as it is more restrictive than the normal version number. - It will default to a per machine level install, giving the user the option to select per user. The assumption here is that by using the MSI rather than the Setup.exe that the intent is either to support a sys admin or GPO install. Optionally the developer can remove this screen my specifying
--instLocation perUseror--instLocation perMachinewhen running vpk pack to specify the location ahead of time. In these cases, the installation location dialog will not be shown to the user. - An optional license can be specified with
--instLicense <License Markdown File>. - It offers very limited customization for the text content. It supports
--instWelcome <Welcome Markdown File>,--instReadMe <Readme Markdown File>, and--instConclusion <Conclusion Markdown File>. Be aware that though these are markdown files, the MSI really only supports plain text in these fields so nearly all formatting is stripped out. - It does not currently expose the ability to leverage any localization parameter (this is expected to be handled with #60)
- It supports setting the header and background bitmaps via the
--msiBanner <Banner Bitmap>and--msiLogo <Background Bitmap>respectively. More discussion is needed on appropriate defaults for these. - It does not do the same bootstrapping of dependencies that the Setup.exe does.
Fixes #389
Maybe side tracking but looking at the code, will this finally bring the option to launch the Uninstall.exe program as an elevated user ?
https://github.com/velopack/velopack/pull/606/files#diff-0dd4454dd2f206a9de82749be468cdaeba3a0b81c37093e1fced6b0902698e72R13-R23
Really looking forward to this as I need to run commands before uninstalling my program like cleaning machine env variables which the current context doesn't allow ...
This brings full elevation support if the program is installed for all users. All hooks will be elevated in that case.
This brings full elevation support if the program is installed for all users. All hooks will be elevated in that case.
Awesome. Can't wait to have this available !
Codecov Report
:x: Patch coverage is 39.14373% with 1393 lines in your changes missing coverage. Please review.
:white_check_mark: Project coverage is 40.82%. Comparing base (fa48e3c) to head (cab8891).
:warning: Report is 7 commits behind head on develop.
Additional details and impacted files
@@ Coverage Diff @@
## develop #606 +/- ##
===========================================
- Coverage 40.87% 40.82% -0.06%
===========================================
Files 244 267 +23
Lines 18355 19457 +1102
Branches 2045 2128 +83
===========================================
+ Hits 7503 7943 +440
- Misses 10497 11125 +628
- Partials 355 389 +34
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
:rocket: New features to boost your workflow:
- :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
- :package: JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.
@Keboo, is this code going to be merged at some point? We're looking for an MSI installer for a project, and would love to use VeloPack. The app consists of a WPF client, a console client, and a Windows service. Because of the Windows service, I don't think we can currently use VeloPack. Thanks!
@jaspet Yes this is what we are working on trying to get merged. However, this is only going to add support for generating an MSI and support for installing an application for all users vs per user. It does not add support for system services. This is on our roadmap but no ETA to report for that feature right now.