diff --git a/manual/microsoft-ui-xaml - 2.8/tools/x64-Microsoft.UI.Xaml.2.8.appx b/manual/microsoft-ui-xaml - 2.8/tools/x64-Microsoft.UI.Xaml.2.8.appx deleted file mode 100644 index 36724e62..00000000 Binary files a/manual/microsoft-ui-xaml - 2.8/tools/x64-Microsoft.UI.Xaml.2.8.appx and /dev/null differ diff --git a/manual/microsoft-ui-xaml - 2.8/tools/x86-Microsoft.UI.Xaml.2.8.appx b/manual/microsoft-ui-xaml - 2.8/tools/x86-Microsoft.UI.Xaml.2.8.appx deleted file mode 100644 index 0b0ce655..00000000 Binary files a/manual/microsoft-ui-xaml - 2.8/tools/x86-Microsoft.UI.Xaml.2.8.appx and /dev/null differ diff --git a/manual/microsoft-ui-xaml - 2.8/README.md b/manual/microsoft-ui-xaml-2-8/README.md similarity index 99% rename from manual/microsoft-ui-xaml - 2.8/README.md rename to manual/microsoft-ui-xaml-2-8/README.md index ab85e2bb..5f0ff1f0 100644 --- a/manual/microsoft-ui-xaml - 2.8/README.md +++ b/manual/microsoft-ui-xaml-2-8/README.md @@ -1,10 +1,10 @@ -# ![Microsoft UI Xaml Logo](https://cdn.jsdelivr.net/gh/pauby/ChocoPackages@54197fd/icons/microsoft-ui-xaml.png "Microsoft UI Xaml Logo") [Microsoft UI Xaml](https://chocolatey.org/packages/microsoft-ui-xaml) - -WinUI is a user interface layer that contains modern controls and styles for building Windows apps. As the native UI layer in Windows it embodies Fluent Design, giving each Windows app the polished feel that customers expect. - -WinUI 2 is a library of controls that provides official native Microsoft UI controls and features for Windows UWP apps. WinUI 2 can be used in any Windows 10 UWP XAML app, or in a Xamarin.Forms app running on Windows 10 using native view embedding. - -WinUI 3 is the next generation of the WinUI framework. It dramatically expands WinUI into a full UX framework, making WinUI available for all types of Windows apps - from Win32 to UWP - for use as the UI layer. - -**NOTE**: The version of this package and the version of the AppX package installed, do not match (for example, version '2.7.0' is actually AppX package version '7.2109.13004.0') -**NOTE**: This is a manually updated package. +# ![Microsoft UI Xaml Logo](https://cdn.jsdelivr.net/gh/pauby/ChocoPackages@54197fd/icons/microsoft-ui-xaml.png "Microsoft UI Xaml Logo") [Microsoft UI Xaml](https://chocolatey.org/packages/microsoft-ui-xaml) + +WinUI is a user interface layer that contains modern controls and styles for building Windows apps. As the native UI layer in Windows it embodies Fluent Design, giving each Windows app the polished feel that customers expect. + +WinUI 2 is a library of controls that provides official native Microsoft UI controls and features for Windows UWP apps. WinUI 2 can be used in any Windows 10 UWP XAML app, or in a Xamarin.Forms app running on Windows 10 using native view embedding. + +WinUI 3 is the next generation of the WinUI framework. It dramatically expands WinUI into a full UX framework, making WinUI available for all types of Windows apps - from Win32 to UWP - for use as the UI layer. + +**NOTE**: The version of this package and the version of the AppX package installed, do not match (for example, version '2.7.0' is actually AppX package version '7.2109.13004.0') +**NOTE**: This is a manually updated package. diff --git a/manual/microsoft-ui-xaml - 2.8/microsoft-ui-xaml.nuspec b/manual/microsoft-ui-xaml-2-8/microsoft-ui-xaml.nuspec similarity index 97% rename from manual/microsoft-ui-xaml - 2.8/microsoft-ui-xaml.nuspec rename to manual/microsoft-ui-xaml-2-8/microsoft-ui-xaml.nuspec index 5568f648..c211f77f 100644 --- a/manual/microsoft-ui-xaml - 2.8/microsoft-ui-xaml.nuspec +++ b/manual/microsoft-ui-xaml-2-8/microsoft-ui-xaml.nuspec @@ -1,87 +1,87 @@ - - - - - - - - - - - - - - - - - - - microsoft-ui-xaml - - - - 2.8.4 - https://github.com/pauby/chocopackages/tree/master/manual/microsoft-ui-xaml - - pauby - - - - - Microsoft.UI.Xaml (Install) - Microsoft - - https://github.com/microsoft/microsoft-ui-xaml - - - https://cdn.jsdelivr.net/gh/pauby/ChocoPackages@54197fd/icons/microsoft-ui-xaml.png - 2023 Microsoft Corporation - - https://github.com/microsoft/microsoft-ui-xaml/blob/main/LICENSE - true - https://github.com/microsoft/microsoft-ui-xaml - https://github.com/microsoft/microsoft-ui-xaml#documentation - - https://github.com/microsoft/microsoft-ui-xaml/issues - microsoft-ui-xaml xaml - WinUI is a user interface layer that contains modern controls and styles for building Windows apps. As the native UI layer in Windows it embodies Fluent Design, giving each Windows app the polished feel that customers expect. - WinUI is a user interface layer that contains modern controls and styles for building Windows apps. As the native UI layer in Windows it embodies Fluent Design, giving each Windows app the polished feel that customers expect. - -WinUI 2 is a library of controls that provides official native Microsoft UI controls and features for Windows UWP apps. WinUI 2 can be used in any Windows 10 UWP XAML app, or in a Xamarin.Forms app running on Windows 10 using native view embedding. - -WinUI 3 is the next generation of the WinUI framework. It dramatically expands WinUI into a full UX framework, making WinUI available for all types of Windows apps - from Win32 to UWP - for use as the UI layer. - -**NOTE**: The version of this package and the version of the AppX package installed, do not match (for example, version '2.7.0' is actually AppX package version '7.2109.13004.0') -**NOTE**: This is a manually updated package. - - https://github.com/microsoft/microsoft-ui-xaml/releases - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + microsoft-ui-xaml-2-8 + + + + 2.8.6 + https://github.com/pauby/chocopackages/tree/master/manual/microsoft-ui-xaml + + pauby + + + + + Microsoft.UI.Xaml (Install) + Microsoft + + https://github.com/microsoft/microsoft-ui-xaml + + + https://cdn.jsdelivr.net/gh/pauby/ChocoPackages@54197fd/icons/microsoft-ui-xaml.png + 2023 Microsoft Corporation + + https://github.com/microsoft/microsoft-ui-xaml/blob/main/LICENSE + true + https://github.com/microsoft/microsoft-ui-xaml + https://github.com/microsoft/microsoft-ui-xaml#documentation + + https://github.com/microsoft/microsoft-ui-xaml/issues + microsoft-ui-xaml xaml + WinUI is a user interface layer that contains modern controls and styles for building Windows apps. As the native UI layer in Windows it embodies Fluent Design, giving each Windows app the polished feel that customers expect. + WinUI is a user interface layer that contains modern controls and styles for building Windows apps. As the native UI layer in Windows it embodies Fluent Design, giving each Windows app the polished feel that customers expect. + +WinUI 2 is a library of controls that provides official native Microsoft UI controls and features for Windows UWP apps. WinUI 2 can be used in any Windows 10 UWP XAML app, or in a Xamarin.Forms app running on Windows 10 using native view embedding. + +WinUI 3 is the next generation of the WinUI framework. It dramatically expands WinUI into a full UX framework, making WinUI available for all types of Windows apps - from Win32 to UWP - for use as the UI layer. + +**NOTE**: The version of this package and the version of the AppX package installed, do not match (for example, version '2.7.0' is actually AppX package version '7.2109.13004.0') +**NOTE**: This is a manually updated package. + + https://github.com/microsoft/microsoft-ui-xaml/releases + + + + + + + + + + + + \ No newline at end of file diff --git a/manual/microsoft-ui-xaml - 2.8/tools/.skipAutoUninstall b/manual/microsoft-ui-xaml-2-8/tools/.skipAutoUninstall similarity index 100% rename from manual/microsoft-ui-xaml - 2.8/tools/.skipAutoUninstall rename to manual/microsoft-ui-xaml-2-8/tools/.skipAutoUninstall diff --git a/manual/microsoft-ui-xaml - 2.8/tools/LICENSE.txt b/manual/microsoft-ui-xaml-2-8/tools/LICENSE.txt similarity index 98% rename from manual/microsoft-ui-xaml - 2.8/tools/LICENSE.txt rename to manual/microsoft-ui-xaml-2-8/tools/LICENSE.txt index 6329ee56..e0010607 100644 --- a/manual/microsoft-ui-xaml - 2.8/tools/LICENSE.txt +++ b/manual/microsoft-ui-xaml-2-8/tools/LICENSE.txt @@ -1,21 +1,21 @@ - MIT License - - Copyright (c) Microsoft Corporation. All rights reserved. - - Permission is hereby granted, free of charge, to any person obtaining a copy - of this software and associated documentation files (the "Software"), to deal - in the Software without restriction, including without limitation the rights - to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - copies of the Software, and to permit persons to whom the Software is - furnished to do so, subject to the following conditions: - - The above copyright notice and this permission notice shall be included in all - copies or substantial portions of the Software. - - THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - SOFTWARE + MIT License + + Copyright (c) Microsoft Corporation. All rights reserved. + + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to deal + in the Software without restriction, including without limitation the rights + to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in all + copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + SOFTWARE diff --git a/manual/microsoft-ui-xaml - 2.8/tools/VERIFICATION.txt b/manual/microsoft-ui-xaml-2-8/tools/VERIFICATION.txt similarity index 80% rename from manual/microsoft-ui-xaml - 2.8/tools/VERIFICATION.txt rename to manual/microsoft-ui-xaml-2-8/tools/VERIFICATION.txt index ba95b112..c805d6bb 100644 --- a/manual/microsoft-ui-xaml - 2.8/tools/VERIFICATION.txt +++ b/manual/microsoft-ui-xaml-2-8/tools/VERIFICATION.txt @@ -1,18 +1,18 @@ - -VERIFICATION -Verification is intended to assist the Chocolatey moderators and community -in verifying that this package's contents are trustworthy. - -1. The software is downloaded from https://www.nuget.org/packages/Microsoft.UI.Xaml/ -2. Select **Versions**, the correct version and then **Download package**. -3. Once downloaded, open in a Zip viewer and go to tools -> AppX -> x64 (or x86) -> Release and you'll find the embedded binary there. -4. You can use one of the following methods to obtain the checksum: - - Use PowerShell function 'Get-Filehash' - - Use chocolatey utility 'checksum.exe' - - x86 checksum: 77DB4857644260B61722A70AA175342DF29ABC8845C1F0AAA7B982F61028AE45 - x86 checksum type: SHA256 - x64 checksum: 0C1D46883629A75BFF7881661E4BB8AC2510983F9341F35D87DC63702CB85118 - x64 checksum type: SHA256 - + +VERIFICATION +Verification is intended to assist the Chocolatey moderators and community +in verifying that this package's contents are trustworthy. + +1. The software is downloaded from https://www.nuget.org/packages/Microsoft.UI.Xaml/ +2. Select **Versions**, the correct version and then **Download package**. +3. Once downloaded, open in a Zip viewer and go to tools -> AppX -> x64 (or x86) -> Release and you'll find the embedded binary there. +4. You can use one of the following methods to obtain the checksum: + - Use PowerShell function 'Get-Filehash' + - Use chocolatey utility 'checksum.exe' + + x86 checksum: 22749BCA3306EC74DAD37F549C777179F90BDE7840FA88F060B8A8B455120897 + x86 checksum type: SHA256 + x64 checksum: 249D2AFB41CC009494841372BD6DD2DF46F87386D535DDF8D9F32C97226D2E46 + x64 checksum type: SHA256 + File 'LICENSE.txt' is obtained from https://github.com/microsoft/microsoft-ui-xaml/blob/main/LICENSE \ No newline at end of file diff --git a/manual/microsoft-ui-xaml - 2.8/tools/chocolateyinstall.ps1 b/manual/microsoft-ui-xaml-2-8/tools/chocolateyinstall.ps1 similarity index 96% rename from manual/microsoft-ui-xaml - 2.8/tools/chocolateyinstall.ps1 rename to manual/microsoft-ui-xaml-2-8/tools/chocolateyinstall.ps1 index 891f3e57..6a919827 100644 --- a/manual/microsoft-ui-xaml - 2.8/tools/chocolateyinstall.ps1 +++ b/manual/microsoft-ui-xaml-2-8/tools/chocolateyinstall.ps1 @@ -1,81 +1,82 @@ -$ErrorActionPreference = 'Stop' - -# This code is borrowed from the awesome Microsoft-Windows-Terminal package -# https://community.chocolatey.org/packages/microsoft-windows-terminal -# -# This can only be installed in a user context. You cannot use Add-AppXPackage -AllUsers (as the parameter is not -# supported). You cannot use *-AppxProvisionedPackage as it produced an unspecified error. - -$toolsDir = "$(Split-Path -Parent $MyInvocation.MyCommand.Definition)" - -. $(Join-Path -Path $toolsDir -ChildPath 'microsoft-ui-xaml-helpers.ps1') - -$windowsVersion = [Environment]::OSVersion.Version -if ($windowsVersion.Major -ne "10") { - throw "This package requires Windows 10 / Server 2019." -} -# .appx is not supported on Windows 10 version 1709 and 1803. https://docs.microsoft.com/en-us/windows/msix/msix-1709-and-1803-support -if ($windowsVersion.Build -lt "17763") { - throw "This package requires at least Windows 10 / Server 2019 version 1809 / OS build 17763.x. See https://github.com/microsoft/microsoft-ui-xaml#version-support for more information." -} - -$removeAppXPackage = $false # used to indicate if we should remove the currently installed AppX package before continuing -# get all of the packages as we may need to use that later -$allAppXPackages = Get-AppXPackage -# there is likely going to be two packages returned for x86 and x64. -# we don't care about the architecture, just the version and they will both be the same. -$installedAppXPackage = @($allAppXPackages | Where-Object -Property Name -eq $internalAppXPackage.PackageName) -if ($installedAppXPackage.Count -gt 0) { - if ([version]$installedAppXPackage[0].Version -gt [version]$internalAppXPackage.Version) { - # you can't install an older version of an installed appx package, you'd need to remove it first - # we also don't want to remove later versions as they will have been installed outside of the package ecosystem - # and may have been installed for very good reasons by another application. - # if the user pases the `-f` or `--force` option to Chocolatey CLI we can attempt uninstall - Write-Warning "The installed $($installedAppXPackage[0].Version) version of the AppX package is newer than the version this Chocolatey package installs, $($internalAppXPackage.Version)." - Write-Warning "It may have been automatically updated on your computer as part of a Windows Update or another application." - - if ($env:ChocolateyForce) { - Write-Host "The '--force' option has been used so we will attempt to remove this later version." - $removeAppXPackage = $true - } - else { - # we will not throw an error if a later version of the AppX package is detected - Write-Warning "We cannot install this package version over the later version without uninstalling it first. Please remove it manually, or run the install command, adding the '--force' option to try and uninstall the later version." - return - } - } - elseif ([version]$installedAppXPackage[0].Version -eq [version]$internalAppxPackage.Version) { - if ($env:ChocolateyForce) { - # you can't install the same version of an appx package, you need to remove it first - Write-Host "The '--force' option has been used so we will attempt to remove the already installed version." - $removeAppXPackage = $true - } - else { - Write-Warning "The $($internalAppXPackage.Version) version of $($internalAppXPackage.PackageName) is already installed. If you want to reinstall, add the '--force' option on the command line." - return - } - } -} - -if ($removeAppXPackage) { - # we need to check we CAN remove the package - if it is a dependent package, it will fail if we try - if (Test-AppXDependency -Name $internalAppXPackage.PackageName -PackageList $allAppXPackages) { - Write-Warning "We cannot remove version $($installedAppXPackage[0].Version) of $($internalAppXPackage.PackageName) as it is a dependency of another AppX package. Please remove it manually and then install this package again." - return - } - - # when you remove a package, you don't remove it per architecture. You just remove it for all architectures. - Write-Host "Attempting to remove version $($installedAppXPackage[0].Version) of $($internalAppXPackage.PackageName). Note that this may fail and you will therefore have to remove it manually." - Remove-AppxPackage -Package $installedAppXPackage[0].PackageFullName -} - -Add-AppxPackage -Path (Join-Path -Path $toolsDir -ChildPath "x86-$($appxFileName)") - -if (Get-OSArchitectureWidth -eq '64') { - Add-AppXPackage -Path (Join-Path -Path $toolsDir -ChildPath "x64-$($appxFileName)") -} - -Write-Warning 'Note that Microsoft may collect data when the Microsoft.UI.Xaml software is installed.' -Write-Warning 'Please see:' -Write-Warning ' https://github.com/microsoft/microsoft-ui-xaml#datatelemetry' +$ErrorActionPreference = 'Stop' + +# This code is borrowed from the awesome Microsoft-Windows-Terminal package +# https://community.chocolatey.org/packages/microsoft-windows-terminal +# +# This can only be installed in a user context. You cannot use Add-AppXPackage -AllUsers (as the parameter is not +# supported). You cannot use *-AppxProvisionedPackage as it produced an unspecified error. + +$toolsDir = "$(Split-Path -Parent $MyInvocation.MyCommand.Definition)" + +. $(Join-Path -Path $toolsDir -ChildPath 'microsoft-ui-xaml-helpers.ps1') + +$windowsVersion = [Environment]::OSVersion.Version +if ($windowsVersion.Major -ne "10") { + throw "This package requires Windows 10 / Server 2019." +} +# .appx is not supported on Windows 10 version 1709 and 1803. https://docs.microsoft.com/en-us/windows/msix/msix-1709-and-1803-support +if ($windowsVersion.Build -lt "17763") { + throw "This package requires at least Windows 10 / Server 2019 version 1809 / OS build 17763.x. See https://github.com/microsoft/microsoft-ui-xaml#version-support for more information." +} + +$removeAppXPackage = $false # used to indicate if we should remove the currently installed AppX package before continuing +# get all of the packages as we may need to use that later +$allAppXPackages = Get-AppXPackage +# there is likely going to be two packages returned for x86 and x64. +# we don't care about the architecture, just the version and they will both be the same. +$installedAppXPackage = @($allAppXPackages | Where-Object -Property Name -eq $internalAppXPackage.PackageName) +if ($installedAppXPackage.Count -gt 0) { + if ([version]$installedAppXPackage[0].Version -gt [version]$internalAppXPackage.Version) { + # you can't install an older version of an installed appx package, you'd need to remove it first + # we also don't want to remove later versions as they will have been installed outside of the package ecosystem + # and may have been installed for very good reasons by another application. + # if the user pases the `-f` or `--force` option to Chocolatey CLI we can attempt uninstall + Write-Warning "The installed $($installedAppXPackage[0].Version) version of the AppX package is newer than the version this Chocolatey package installs, $($internalAppXPackage.Version)." + Write-Warning "It may have been automatically updated on your computer as part of a Windows Update or another application." + + if ($env:ChocolateyForce) { + Write-Host "The '--force' option has been used so we will attempt to remove this later version." + $removeAppXPackage = $true + } + else { + # we will not throw an error if a later version of the AppX package is detected + Write-Warning "We cannot install this package version over the later version without uninstalling it first. Please remove it manually, or run the install command, adding the '--force' option to try and uninstall the later version." + return + } + } + elseif ([version]$installedAppXPackage[0].Version -eq [version]$internalAppxPackage.Version) { + if ($env:ChocolateyForce) { + # you can't install the same version of an appx package, you need to remove it first + Write-Host "The '--force' option has been used so we will attempt to remove the already installed version." + $removeAppXPackage = $true + } + else { + Write-Warning "The $($internalAppXPackage.Version) version of $($internalAppXPackage.PackageName) is already installed. If you want to reinstall, add the '--force' option on the command line." + return + } + } +} + +if ($removeAppXPackage) { + # we need to check we CAN remove the package - if it is a dependent package, it will fail if we try + if (Test-AppXDependency -Name $internalAppXPackage.PackageName -PackageList $allAppXPackages) { + Write-Warning "We cannot remove version $($installedAppXPackage[0].Version) of $($internalAppXPackage.PackageName) as it is a dependency of another AppX package. Please remove it manually and then install this package again." + return + } + + # when you remove a package, you don't remove it per architecture. You just remove it for all architectures. + Write-Host "Attempting to remove version $($installedAppXPackage[0].Version) of $($internalAppXPackage.PackageName). Note that this may fail and you will therefore have to remove it manually." + Remove-AppxPackage -Package $installedAppXPackage[0].PackageFullName +} + +if (Get-OSArchitectureWidth -eq '64') { + Add-AppXPackage -Path (Join-Path -Path $toolsDir -ChildPath "x64-$($appxFileName)") +} +else { + Add-AppxPackage -Path (Join-Path -Path $toolsDir -ChildPath "x86-$($appxFileName)") +} + +Write-Warning 'Note that Microsoft may collect data when the Microsoft.UI.Xaml software is installed.' +Write-Warning 'Please see:' +Write-Warning ' https://github.com/microsoft/microsoft-ui-xaml#datatelemetry' Write-Warning ' https://github.com/microsoft/microsoft-ui-xaml/blob/main/docs/developer_guide.md#telemetry' \ No newline at end of file diff --git a/manual/microsoft-ui-xaml - 2.8/tools/chocolateyuninstall.ps1 b/manual/microsoft-ui-xaml-2-8/tools/chocolateyuninstall.ps1 similarity index 98% rename from manual/microsoft-ui-xaml - 2.8/tools/chocolateyuninstall.ps1 rename to manual/microsoft-ui-xaml-2-8/tools/chocolateyuninstall.ps1 index 33ba4540..fdacd159 100644 --- a/manual/microsoft-ui-xaml - 2.8/tools/chocolateyuninstall.ps1 +++ b/manual/microsoft-ui-xaml-2-8/tools/chocolateyuninstall.ps1 @@ -1,25 +1,25 @@ -$ErrorActionPreference = 'Stop' - -$toolsDir = "$(Split-Path -Parent $MyInvocation.MyCommand.Definition)" - -. $(Join-Path -Path $toolsDir -ChildPath 'microsoft-ui-xaml-helpers.ps1') - -$allAppXPackages = Get-AppxPackage -# there is likely going to be two packages returned for x86 and x64. -# we don't care about the architecture, just the version and they will both be the same. -$installedAppXPackage = @($allAppXPackages | Where-Object -Property Name -eq $internalAppXPackage.PackageName) -if ($installedAppXPackage.Count -gt 0) { - # check there are no packages that take our package as a dependency - if (Test-AppXDependency -Name $internalAppXPackage.PackageName -PackageList $allAppXPackages) { - Write-Warning "We cannot remove $($internalAppXPackage.PackageName) as it is a dependency of another AppX package. Please remove it manually and then install this package again." - return - } - else { - # when you remove a package, you don't remove it per architecture. You just remove it for all architectures. - Write-Host "Attempting to remove $($internalAppXPackage.PackageName). Note that this may fail and you will therefore have to remove it manually." - Remove-AppxPackage -Package $installedAppXPackage[0].PackageFullName - } -} -else { - Write-Warning "The $($internalAppXPackage.PackageName) AppX package does not appear to be installed." +$ErrorActionPreference = 'Stop' + +$toolsDir = "$(Split-Path -Parent $MyInvocation.MyCommand.Definition)" + +. $(Join-Path -Path $toolsDir -ChildPath 'microsoft-ui-xaml-helpers.ps1') + +$allAppXPackages = Get-AppxPackage +# there is likely going to be two packages returned for x86 and x64. +# we don't care about the architecture, just the version and they will both be the same. +$installedAppXPackage = @($allAppXPackages | Where-Object -Property Name -eq $internalAppXPackage.PackageName) +if ($installedAppXPackage.Count -gt 0) { + # check there are no packages that take our package as a dependency + if (Test-AppXDependency -Name $internalAppXPackage.PackageName -PackageList $allAppXPackages) { + Write-Warning "We cannot remove $($internalAppXPackage.PackageName) as it is a dependency of another AppX package. Please remove it manually and then install this package again." + return + } + else { + # when you remove a package, you don't remove it per architecture. You just remove it for all architectures. + Write-Host "Attempting to remove $($internalAppXPackage.PackageName). Note that this may fail and you will therefore have to remove it manually." + Remove-AppxPackage -Package $installedAppXPackage[0].PackageFullName + } +} +else { + Write-Warning "The $($internalAppXPackage.PackageName) AppX package does not appear to be installed." } \ No newline at end of file diff --git a/manual/microsoft-ui-xaml - 2.8/tools/microsoft-ui-xaml-helpers.ps1 b/manual/microsoft-ui-xaml-2-8/tools/microsoft-ui-xaml-helpers.ps1 similarity index 86% rename from manual/microsoft-ui-xaml - 2.8/tools/microsoft-ui-xaml-helpers.ps1 rename to manual/microsoft-ui-xaml-2-8/tools/microsoft-ui-xaml-helpers.ps1 index 35840ffd..4da40b42 100644 --- a/manual/microsoft-ui-xaml - 2.8/tools/microsoft-ui-xaml-helpers.ps1 +++ b/manual/microsoft-ui-xaml-2-8/tools/microsoft-ui-xaml-helpers.ps1 @@ -1,33 +1,33 @@ -$ErrorActionPreference = 'Stop' - -$internalAppXPackage = @{ - SoftwareName = 'Microsoft.UI.Xaml' - PackageName = 'Microsoft.Ui.Xaml.2.8' - Version = '8.2305.5001.0' -} - -$appxFileName = 'Microsoft.UI.Xaml.2.8.appx' -$packagedAppxVersion = '2.8.4' - -function Test-AppXDependency { - [CmdletBinding()] - - Param ( - [Parameter(Mandatory = $true)] - [String] - $Name, - - # An array of packages that should be the output from Get-AppXPackages - [Parameter(Mandatory = $true)] - [Object[]] - $PackageList - ) - - ForEach ($pkg in $PackageList) { - if ($pkg.Dependencies.Name -contains $Name) { - return $true - } - } - - return $false +$ErrorActionPreference = 'Stop' + +$internalAppXPackage = @{ + SoftwareName = 'Microsoft.UI.Xaml' + PackageName = 'Microsoft.Ui.Xaml.2.8' + Version = '8.2310.30001.0' +} + +$appxFileName = 'Microsoft.UI.Xaml.2.8.appx' +$packagedAppxVersion = '2.8.6' + +function Test-AppXDependency { + [CmdletBinding()] + + Param ( + [Parameter(Mandatory = $true)] + [String] + $Name, + + # An array of packages that should be the output from Get-AppXPackages + [Parameter(Mandatory = $true)] + [Object[]] + $PackageList + ) + + ForEach ($pkg in $PackageList) { + if ($pkg.Dependencies.Name -contains $Name) { + return $true + } + } + + return $false } \ No newline at end of file diff --git a/manual/microsoft-ui-xaml-2-8/tools/x64-Microsoft.UI.Xaml.2.8.appx b/manual/microsoft-ui-xaml-2-8/tools/x64-Microsoft.UI.Xaml.2.8.appx new file mode 100644 index 00000000..e2a4196f Binary files /dev/null and b/manual/microsoft-ui-xaml-2-8/tools/x64-Microsoft.UI.Xaml.2.8.appx differ diff --git a/manual/microsoft-ui-xaml-2-8/tools/x86-Microsoft.UI.Xaml.2.8.appx b/manual/microsoft-ui-xaml-2-8/tools/x86-Microsoft.UI.Xaml.2.8.appx new file mode 100644 index 00000000..cc6b2107 Binary files /dev/null and b/manual/microsoft-ui-xaml-2-8/tools/x86-Microsoft.UI.Xaml.2.8.appx differ diff --git a/manual/microsoft-ui-xaml/microsoft-ui-xaml.nuspec b/manual/microsoft-ui-xaml/microsoft-ui-xaml.nuspec index d1ff7b84..8ecf6362 100644 --- a/manual/microsoft-ui-xaml/microsoft-ui-xaml.nuspec +++ b/manual/microsoft-ui-xaml/microsoft-ui-xaml.nuspec @@ -26,7 +26,7 @@ This is a nuspec. It mostly adheres to https://docs.nuget.org/create/Nuspec-Refe - 2.7.3 + 2.8.6 https://github.com/pauby/chocopackages/tree/master/manual/microsoft-ui-xaml pauby @@ -34,7 +34,7 @@ This is a nuspec. It mostly adheres to https://docs.nuget.org/create/Nuspec-Refe - Microsoft.UI.Xaml 2.7 (Install) + Microsoft.UI.Xaml 2.8 (Install) Microsoft https://github.com/microsoft/microsoft-ui-xaml @@ -62,7 +62,7 @@ WinUI 3 is the next generation of the WinUI framework. It dramatically expands W https://github.com/microsoft/microsoft-ui-xaml/releases - +