winget-cli icon indicating copy to clipboard operation
winget-cli copied to clipboard

Make Microsoft.WinGet.Client PowerShell cmdlets "singular" in name

Open denelon opened this issue 1 year ago • 4 comments

Description of the new feature / enhancement

The following cmdlets are plural in name and should be singular:

  • Get-WinGetSettings
  • Get-WinGetUserSettings
  • Set-WinGetUserSettings
  • Test-WinGetUserSettings

Proposed technical implementation details

No response

denelon avatar Jul 26 '24 18:07 denelon

These should be made into "singular" names, and the "plural" name should become an alias so users who have scripted against this aren't broken.

denelon avatar Jul 29 '24 16:07 denelon

[...] the "plural" name should become an alias so users who have scripted against this aren't broken.

F*** 'em. Break it now while it's still fresh, you don't wanna become the ShellFolders of the 21st century. No alias!

jantari avatar Aug 01 '24 21:08 jantari

@denelon I'll add this into the following PR #4716

kilasuit avatar Aug 09 '24 13:08 kilasuit

There is an anti-pattern when putting all "settings" into a single cmdlet. Ideally there would be a cmdlet(s) to set the individual setting.

Here are some examples that aren't real WinGet values.

Disable-WinGetHashValidation
Enable-WinGetHashValidation

Set-WinGetTimeout
Get-WinGetTimeout

Lets take Get-WinGetSettings cmdlet. The output is not user friendly at all. First it returns a case sensitive hashtable. The is not a good way to parse the settings at a glance. There is not an easy way for me to determine which settings I can set with Set-WinGetSettings since it takes a hashtable which could be anything.

ThomasNieto avatar Aug 16 '24 02:08 ThomasNieto