Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add --no-progress global option to hide all progress animations #5098

Merged
merged 6 commits into from
Jul 16, 2024

Conversation

silvanocerza
Copy link
Contributor

@silvanocerza silvanocerza commented Jul 16, 2024

Summary

Fixes #5082.

Adds a new Printer::NoProgress that is identical to Printer::Default but doesn't draw any progress bar.

Test Plan

It seems to me that as of now it's not possible to use insta-cmd to get any progress bar in the comparable output of command.

Best way to test this would be to run any command that usually shows progress indicators like uv pip install with and without --no-progress options.

@zanieb zanieb requested a review from ibraheemdev July 16, 2024 14:44
crates/uv-cli/src/lib.rs Outdated Show resolved Hide resolved
Copy link
Member

@zanieb zanieb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The approach looks reasonable to me!

@ibraheemdev
Copy link
Member

ibraheemdev commented Jul 16, 2024

Maybe --no-progress is a better name, because this hides all progress output, not just bars? We previously discussed an option that would hide the concurrent progress bars but still show a top-level progress indicator.

@silvanocerza silvanocerza marked this pull request as ready for review July 16, 2024 21:19
@zanieb zanieb added the cli Related to the command line interface label Jul 16, 2024
@zanieb zanieb changed the title Add --no-progress-bar global option to hide all progress bars Add --no-progress global option to hide all progress animations Jul 16, 2024
@zanieb zanieb merged commit 426736f into astral-sh:main Jul 16, 2024
51 checks passed
@zanieb
Copy link
Member

zanieb commented Jul 16, 2024

Thanks again!

@silvanocerza silvanocerza deleted the no-progress-bar-option branch July 17, 2024 11:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cli Related to the command line interface
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Provide a flag to disable spinner during uv pip sync/install
3 participants