Skip to content

Conversation

@PhantomInTheWire
Copy link

@PhantomInTheWire PhantomInTheWire commented Nov 19, 2025

Type of Change

  • Bug fix
  • New feature
  • Breaking change
  • Documentation update

Motivation and Context

relevant issue: #641

Adds two new modes to --progress: plain and color.

  • plain: Produces simple, line-by-line text output with no ANSI escape codes. Ideal for writing to log files or environments that don’t support terminal control sequences.

  • color: Similar to the existing ANSI mode but with enhanced color usage. This mode provides a more expressive visual display. If it sounds good, we could consider making it the default in this or a follow up pr.

Testing

  • Tested locally
  • Added/updated tests
  • Added/updated docs

@PhantomInTheWire PhantomInTheWire force-pushed the feat/color-plain branch 5 times, most recently from 345bf01 to c59d4d2 Compare November 22, 2025 21:49
@saehejkang
Copy link
Contributor

I don't see anything out of the ordinary on these changes, but I also don't have permissions to approve PRs. You will have to wait for a maintainer to come back to this for a ✅ .

Comment on lines 68 to 71
/// The flag indicating whether to use colors.
public let color: Bool
/// The flag indicating whether to use plain output (no ANSI codes, one line per update).
public let plain: Bool
Copy link
Contributor

Choose a reason for hiding this comment

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

Could we use an enum instead of these booleans to indicate the type of the output?

Copy link
Author

Choose a reason for hiding this comment

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

i was avoiding that since that would involve changing a widely used api would touch a lot unrelated lines but it does seem to make this a little bit more cleaner overall

Copy link
Author

Choose a reason for hiding this comment

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

refactored.

@PhantomInTheWire
Copy link
Author

@katiewasnothere @saehejkang what do you guys think about making color mode the default mode instead of ansi since it visually looks a lot more appealing?

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants