Skip to content

Option to disable spinner as a command line argument #3494

Description

@giggio

Description of the new feature / enhancement

Add an option to disable the spinner and any other progress indicator.
This adds clutter to the screen if you are trying to capture what happened, and makes it harder to process winget output with command line tools.

Proposed technical implementation details

Add an option to the settings.json file (done) and a command line argument.

Activity

  1. denelon commented on Aug 3, 2023

    @denelon
    Collaborator

    You might want to give the "Microsoft.WinGet.Client" PowerShell module or look at the COM API in WinGet for automation scenarios.

  2. giggio commented on Aug 3, 2023

    @giggio
    Author

    I'm using the PowerShell module, but it is still incomplete. I need the pins to be available there.
    I'll check out the COM API.
    Still, one might need to capture the output, for example, in CI scenarios, and it will produce a lot of unnecessary text.

  3. giggio commented on Aug 3, 2023

    @giggio
    Author

    I just checked out the API, you can't manage pins through it, either.
    https://github.com/microsoft/winget-cli/blob/master/doc/specs/%23888%20-%20Com%20Api.md

  4. markusheiliger commented on Sep 29, 2023

    @markusheiliger

    I agree with Giovanni Bassi (@giggio). Getting rid of the spinner output using a command line argument would help to get the captured output clean. BTW, the same applies to the download progress output IMO. TBH I would expect all this output suppressed when using a the /silent switch.

    And no, switching to the PowerShell module or using the COM API is no option for me. The automation script works as it is. It's just tooooo noisy!

  5. mdanish-kh commented on Nov 29, 2023

    @mdanish-kh
    Contributor

    [Policy] Area-Output

  6. jantari commented on Dec 18, 2023

    @jantari

    The spinners should always be disabled when --disable-interactivity parameter is specified by the user.

    If interactive features are explicitly disabled, there is absolutely no reason to print spinners, which are a purely interactive feature.

  7. igorakkerman commented on Feb 8, 2024

    @igorakkerman

    Here's my current workaround to skip spinners, progress bars and blank lines:

        # patterns to omit in output
        $spinners = '\', '/', '|', '-' | ForEach-Object { "^\s*\$_\s*`$" } | Join-String -Separator '|'
        $progressBars = '█', '▒' | ForEach-Object { "^.+\$_.+`$" } | Join-String -Separator '|'
        $blankLine = '^\s*$'
        $skip = "$spinners|$progressBars|$blankLine"
    
        winget upgrade `
            --all `
            --accept-source-agreements `
            --accept-package-agreements `
            --silent `
            --disable-interactivity `
        | Select-String -NotMatch $skip
  8. asheroto commented on Feb 14, 2024

    @asheroto

    I did something similar but replaced the characters instead of using Select-String so that the output could be viewed in real-time...

    https://gist.github.com/asheroto/96bcabe428e8ad134ef204573810041f

  9. apcsb commented on Apr 25, 2024

    @apcsb

    My solution for lists and tables so far was to look for the separator line (--------------) and trim everything before it +/- 1 line (in some scripts I need to parse the headers, since winget list, for example, can produce a different number of columns). But you always get the line.

    $output = WinGet.exe $params
    $lineNumber = $output.IndexOf($output -match '----+') - 2 #-2 returns the header line. W/o -2 you get all past the separator line
    if ($lineNumber -lt 0) { return $null}
    return $output[$lineNumber..($output.Length-1)]
    

    To make matter worse, when the output is captured in a string, you get encoding issues and skewed columns
    Here's an example of winget list - check the Inter Graphics Command Center name and id
    We need --disable-interactivity to properly handle all this

    Interactive

    Name                                                        Id                                                               Version            Available    Source
    -------------------------------------------------------------------------------------------------------------------------------------------------------------------  
    LogiOptionsWordAddin                                        2C559D7A6B8C383AF1FC7ED06D375EAC624F143E6F778C4FCDD50D9E023A4354 10.10.4.0
    Tag Explorer                                                46887Dr.Cooper.TagExplorer_s0pf5z833f2vc                         3.7.0.0
    Ritt                                                        62283Ritt.Ritt_qr54r3v2h1vqw                                     1.4.0.0
    Visual Studio Enterprise 2022                               Microsoft.VisualStudio.2022.Enterprise                           17.9.6                          winget  
    LogiOptionsExcelAddin                                       67C3222594B96ED78A8AA3050861B9C717ACC01FF3F90093DB70B6D61707DA57 10.10.4.0
    LogiOptionsPowerPointAddin                                  75B10E1044297ED2ACEE0B524BDF62C55A10D7609038BE3D371ABA95D4F4DA6F 10.10.4.0
    Intel® Graphics Command Center                              AppUp.IntelGraphicsExperience_8j3eq9eme6ctt                      1.100.5435.0
    ThunderboltTM Control Center                                AppUp.ThunderboltControlCenter_8j3eq9eme6ctt                     1.0.37.0
    

    Captured into a string

       \ 
       | 
    
    Name                                    Id                                       Version            Available    Source
    -----------------------------------------------------------------------------------------------------------------------
    LogiOptionsWordAddin                    2C559D7A6B8C383AF1FC7ED06D375EAC624F143… 10.10.4.0
    Tag Explorer                            46887Dr.Cooper.TagExplorer_s0pf5z833f2vc 3.7.0.0
    Ritt                                    62283Ritt.Ritt_qr54r3v2h1vqw             1.4.0.0
    Visual Studio Enterprise 2022           Microsoft.VisualStudio.2022.Enterprise   17.9.6                          winget
    LogiOptionsExcelAddin                   67C3222594B96ED78A8AA3050861B9C717ACC01… 10.10.4.0
    LogiOptionsPowerPointAddin              75B10E1044297ED2ACEE0B524BDF62C55A10D76… 10.10.4.0
    Intel® Graphics Command Center          AppUp.IntelGraphicsExperience_8j3eq9eme… 1.100.5435.0
    ThunderboltTM Control Center            AppUp.ThunderboltControlCenter_8j3eq9em… 1.0.37.0
    
  10. AdreKiseque commented on Feb 22, 2025

    @AdreKiseque

    As far as I can tell, this feature is already implemented? The issue should probably be closed, in that case.

  11. giggio commented on Feb 22, 2025

    @giggio
    Author

    As far as I can tell, this feature is already implemented? The issue should probably be closed, in that case.

    André Fertig de Oliveira (@AdreKiseque) how so? You linked to config file, that is not an option. I'd only disable progress when piping to another tool, not on every use. Using a global option does not make sense for the provided use case.

  12. 5 remaining items

  13. denelon commented on Feb 17, 2026

    @denelon
    Collaborator
  14. linked a pull request that will close this issueAdd --no-progress option #6049on Feb 17, 2026
  15. giggio commented on Feb 18, 2026

    @giggio
    Author

    It is possible to disable the spinner in WinGet Settings.

    Demitrius Nelon (@denelon) I'm aware, this issue touches that (already fixed) and a command line option. See the issue description.

  16. changed the title [-]Option to disable spinner[/-] [+]Option to disable spinner as a command line argument[/+] on Feb 18, 2026
  17. moved this from In Progress to Done in WinGeton Feb 18, 2026
  18. denelon commented on Feb 18, 2026

    @denelon
    Collaborator

    Giovanni Bassi (@giggio) I think we crossed paths with some of the work happening. The PR to add the argument was just merged. I'm expecting the next preview with that feature to get published within a couple of weeks.

  19. cachius commented on Feb 19, 2026

    @cachius

    Thanks Demitrius Nelon (@denelon).
    For reference, the option to disable via settings.json in %LOCALAPPDATA%\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState or if self-built in %LOCALAPPDATA%\Microsoft\WinGet\Settings is

    {
        "$schema": "https://aka.ms/winget-settings.schema.json",
        "visual": {
            "progressBar": "disabled"
        }
    }
    
  20. God-damnit-all commented on Feb 24, 2026

    @God-damnit-all

    @giggio I think we crossed paths with some of the work happening. The PR to add the argument was just merged. I'm expecting the next preview with that feature to get published within a couple of weeks.

    Is there a particular reason that the spinner is tied to stdout in the first place? Utilities like curl tend to display progress on stderr so even if you're redirecting stdout you can still see how far along it is.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Area-OutputIssue related to CLI outputIn-PRIssue related to a PRIssue-FeatureThis is a feature request for the Windows Package Manager client.

Projects

  • Status
    Done

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions