Skip to content

Commit 0b97c5e

Browse files
petrischpatrick.joerg
andauthored
Add --upgrade-available flag to winget list (#1182)
The command had to be renamed to --upgrade_available because nu wouldn't parse it otherwise. Not sure if this is the best way or if this is the exact reason why it hasn't been added since. Co-authored-by: patrick.joerg <[email protected]>
1 parent 9ce0d5d commit 0b97c5e

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

custom-completions/winget/winget-completions.nu

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -292,6 +292,7 @@ export def "winget list" [
292292
--exact(-e), # Find package using exact match
293293
--header: string, # Optional Windows-Package-Manager REST source HTTP header
294294
--accept_source_agreements, # Accept all source agreements during source operations
295+
--upgrade_available # Filter results by available upgrade
295296
--raw, # Output the raw CLI output instead of structured data
296297
--help(-?) # Display the help for this command
297298
] {
@@ -315,8 +316,9 @@ export def "winget list" [
315316
(do $flagify exact $exact)
316317
(do $flagify header $header)
317318
(do $flagify accept_source_agreements $accept_source_agreements)
319+
(do $flagify upgrade-available $upgrade_available)
318320
(do $flagify help $help)
319-
]
321+
]
320322
| flatten
321323
| where { not ($in | is-empty) })
322324
)

0 commit comments

Comments
 (0)