Open jdhitsolutions opened 1 year ago
For an unofficial implementation, consider starting with Search-WinGetManifest
and replacing a couple of words to arrive at Show-WinGetPackage
:
Function Show-WinGetPackage ($term) {
$out = WinGet show $term --disable-interactivity #| where {$_ -notmatch "Γûê"}
return $out
}
From here, the output could be parsed and modified using Select
before return.
I am doing something similar with Get-WGPackage from my WingetTools module.
PS C:\> get-wgpackage -id WestWind.MarkdownMonster | select *
Moniker : markdown-monster
Description : MarkdownMonster A powerful, yet easy to use Markdown Editor for Windows
Author : Rick Strahl, West Wind Technologies
Publisher : West Wind Technologies
PublisherUrl : https://markdownmonster.west-wind.com
PublisherSupportUrl : https://markdownmonster.west-wind.com/docs/_4s0144w3g.htm
Homepage : https://markdownmonster.west-wind.com
Name : Markdown Monster
ID : WestWind.MarkdownMonster
Version : 3.0.8.0
Source : winget
Computername : PROSPERO
I am hoping for a more native solution that doesn't require parsing YAML.
Instead of a new command, you could add the manifest details as a metadata property on the output object. Find-Module
does that with an AdditionalMetadata
property.
Description of the new feature / enhancement
The cli tool lets me get package details.
But I can't find a comparable equivalent in the PowerShell module. The find command is limited.
Proposed technical implementation details
Show
is a valid verb so you should be able to addShow-Wingetpackage
and write a structured object to the pipeline. The command should write a structured object to the pipeline with these properties.Tags
should be an array property.I'd make the
Installer
property a nested object.