feat: colorize dataset install and download progress output - #42
Merged
Conversation
Extract cli.rs's Tone/styled helpers into a shared style module so the installer's messages (data.rs) and progress bar (dataset_download.rs) follow the same terminal-aware red/yellow/green convention already used for interaction results, instead of being plain text.
CI's cargo fmt --check job caught a line rustfmt wants split across multiple lines.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
cli.rs'sTone/styledhelpers into a sharedstyle.rsmodule (styled_outfor stdout,styled_errfor stderr), so the color convention isn't duplicated per module.data.rs's install-flow messages (warning when no database is found, the install prompt, download/success/fallback lines).dataset_download.rs's live progress bar.is_terminal(), so piped/redirected output is unaffected.Test plan
cargo build --release -p mensung-clientcargo test -p mensung-client(35 passed, 2 ignored live-network tests unaffected)cargo clippy -p mensung-client --release -- -D warnings(clean)