Change return type of lists from winget #1506
Labels
Issue-Feature
This is a feature request for the Windows Package Manager client.
Resolution-Duplicate
Issue is a duplicate
Milestone
Description of the new feature/enhancement
Currently, when lists are returned from winget, like in
winget upgrade
, the list is merely an array of strings. This makes it harder to use features such as powershell filtering.Proposed technical implementation details (optional)
Instead of returning an array of strings, when running in powershell, return an array of objects, like the Get-Process commandlet does. Powershell as already able to convert an array into a table, so doing it the current way does not make sense to me.
With this, we could for example use
winget upgrade | where Version -ne "Unknown"
to get a list of all packages that we can retrieve versions for, as some packages do not show their current version, even if installed via winget.The text was updated successfully, but these errors were encountered: