Track support of minimum age in managers#4808
Open
Sébastien Duquette (sduquette-devolutions) wants to merge 1 commit into
Open
Track support of minimum age in managers#4808Sébastien Duquette (sduquette-devolutions) wants to merge 1 commit into
Sébastien Duquette (sduquette-devolutions) wants to merge 1 commit into
Conversation
We now use the value of SupportsMinimumAge to display which package managers support this setting.
Copilot started reviewing on behalf of
Sébastien Duquette (sduquette-devolutions)
May 21, 2026 00:48
View session
Contributor
There was a problem hiding this comment.
Pull request overview
This PR introduces a SupportsMinimumAge capability on package managers and updates both WinUI and Avalonia settings UIs to use that capability when enabling/showing “minimum update age” support (based on availability of package release/update dates).
Changes:
- Added
SupportsMinimumAgetoManagerCapabilities. - Updated WinUI + Avalonia settings pages to use
manager.Capabilities.SupportsMinimumAgeinstead of hardcoded manager-name lists. - Marked Pip/Npm/Cargo/Bun as supporting minimum update age; updated
.gitignoreto ignorewinget-cli_x64/.
Reviewed changes
Copilot reviewed 9 out of 10 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| src/UniGetUI/Pages/SettingsPages/ManagersPages/PackageManager.xaml.cs | Uses Capabilities.SupportsMinimumAge to enable/disable per-manager minimum update age UI. |
| src/UniGetUI/Pages/SettingsPages/GeneralPages/Updates.xaml.cs | Uses Capabilities.SupportsMinimumAge for the release-date compatibility table. |
| src/UniGetUI.PackageEngine.Managers.Pip/Pip.cs | Sets SupportsMinimumAge = true for Pip. |
| src/UniGetUI.PackageEngine.Managers.Npm/Npm.cs | Sets SupportsMinimumAge = true for Npm. |
| src/UniGetUI.PackageEngine.Managers.Cargo/Cargo.cs | Sets SupportsMinimumAge = true for Cargo. |
| src/UniGetUI.PackageEngine.Managers.Bun/Bun.cs | Sets SupportsMinimumAge = true for Bun. |
| src/UniGetUI.PackageEngine.Enums/ManagerCapabilities.cs | Adds the new SupportsMinimumAge capability flag. |
| src/UniGetUI.Avalonia/Views/Pages/SettingsPages/PackageManagerPage.axaml.cs | Uses Capabilities.SupportsMinimumAge to enable/disable per-manager minimum update age UI (Avalonia). |
| src/UniGetUI.Avalonia/ViewModels/Pages/SettingsPages/UpdatesViewModel.cs | Uses Capabilities.SupportsMinimumAge for the compatibility table (Avalonia). |
| .gitignore | Removes old choco-cli ignore entries; adds winget-cli_x64/. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
35
to
41
| public bool SupportsCustomSources = false; | ||
| public bool SupportsCustomPackageIcons = false; | ||
| public bool SupportsCustomPackageScreenshots = false; | ||
| public bool SupportsMinimumAge = false; | ||
| public ProxySupport SupportsProxy = ProxySupport.No; | ||
| public bool SupportsProxyAuth = false; | ||
| public SourceCapabilities Sources { get; set; } |
Comment on lines
127
to
132
| int row = i + 1; | ||
| var name = new TextBlock { Text = manager.DisplayName, VerticalAlignment = VerticalAlignment.Center }; | ||
| Grid.SetRow(name, row); Grid.SetColumn(name, 0); | ||
| bool supported = !_managersWithoutUpdateDate.Contains(manager.Name); | ||
| bool supported = manager.Capabilities.SupportsMinimumAge; | ||
| var badge = MakeStatusBadge(supported ? yesStr : noStr, supported); | ||
| Grid.SetRow(badge, row); Grid.SetColumn(badge, 1); |
Comment on lines
491
to
495
|
|
||
| bool initiallyCustomAge = savedAgeVal == "custom"; | ||
| bool ageSupported = !_managersWithoutUpdateDate.Contains(Manager.Name); | ||
| bool ageSupported = Manager.Capabilities.SupportsMinimumAge; | ||
|
|
||
| object ageCardDescription = !ageSupported |
Comment on lines
85
to
90
| var name = new TextBlock { Text = manager.DisplayName, VerticalAlignment = VerticalAlignment.Center }; | ||
| Grid.SetRow(name, row); Grid.SetColumn(name, 0); | ||
|
|
||
| bool supported = !_managersWithoutUpdateDate.Contains(manager.Name); | ||
| bool supported = manager.Capabilities.SupportsMinimumAge; | ||
| var badge = _statusBadge(supported ? yesStr : noStr, supported ? Colors.Green : Colors.Red); | ||
| Grid.SetRow(badge, row); Grid.SetColumn(badge, 1); |
Comment on lines
257
to
261
| }; | ||
|
|
||
| bool initiallyCustom = savedAge == "custom"; | ||
| bool ageSupported = !_managersWithoutUpdateDate.Contains(manager.Name); | ||
| bool ageSupported = manager.Capabilities.SupportsMinimumAge; | ||
| object ageDescription = !ageSupported |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
We define SupportsMinimumAge in the manager classes and use this value to display which package managers support this setting.