mirror of
https://github.com/microsoft/terminal.git
synced 2025-12-11 04:38:24 -06:00
Since the removal of the Win10-specific variant of the Terminal MSIX in #15031, there has been no officially-sanctioned (or even unofficially tested!) way to get an unzippable double-click-runnable version of Windows Terminal. Due to a quirk in the resource loading system, an unpackaged distribution of Terminal needs to ship all of XAML's resources and all of is own resources in a single `resources.pri` file. The tooling to support this is minimal, and we were previously just coasting by on Visual Studio's generosity plus how the prerelease distribution of XAML embedded itself into the consuming package. This pull request introduces a build phase plus a supporting script (or three) that produces a ZIP file distribution of Windows Terminal when given a Terminal MSIX and an XAML AppX. The three scripts are: 1. A script to merge any number of PRI files and/or PRI dump files (made with `makepri dump /dt detailed`) 2. A script that specifically merges XAML's resources with Terminal's. This is necessary because the XAML package emits a couple PRI resources into Terminal's resources _even when it is not co-packaged._ We need to remove the conflicting resources. 3. Finally, a script to take a WT and XAML distribution and combine them -- resources, files, everything -- and strip out the things that we don't need. This script is an all-in-one that calls the other two and produces a ZIP file at the end. The final distribution is named after the PFN (`Microsoft.WindowsTerminal`, or `...Preview` or `WindowsTerminalDev`), the version number and the architecture. When expanded, it produces a directory named `terminal-X.Y.Z.A` (version number.) I've also added the build script to the release pipeline. As a treat, this also produces an unpackaged distribution out of every CI build... that way, contributors can download live deployable copies of WT Unpackaged to test out their changes. Pretty cool. Refs #1386