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

[Collection] Simple colorize collection text like Bundler #1558

Merged
merged 3 commits into from
Oct 17, 2023

Conversation

ksss
Copy link
Collaborator

@ksss ksss commented Oct 5, 2023

I propose adding color to the log outputs of the collection.
As the current logs generated by the collection aren't colored, there's a potential for misunderstanding whether a log is indicating an error or not.
It appears that the text is based on Bundler, so I've taken a cue from Bundler for the coloration. "Installing", "Updating", and the final "It's done!" are colored in green, while "Using" retains its current color. This makes the command's success more evident.

image

Copy link
Member

@soutaro soutaro left a comment

Choose a reason for hiding this comment

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

Good to merge!
We may want a flag to disable colorization for testing, like Rainbow.enabled = false.

@soutaro
Copy link
Member

soutaro commented Oct 16, 2023

We may want to see NO_COLOR? https://no-color.org

@ksss
Copy link
Collaborator Author

ksss commented Oct 16, 2023

@ksss
Copy link
Collaborator Author

ksss commented Oct 16, 2023

I have made a modification so that the color toggle can be switched with the environment variable NO_COLOR.

Copy link
Member

@soutaro soutaro left a comment

Choose a reason for hiding this comment

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

🙏 💯

@soutaro soutaro added this pull request to the merge queue Oct 17, 2023
Merged via the queue into ruby:master with commit 88523a3 Oct 17, 2023
23 checks passed
@ksss ksss deleted the collection-color branch October 17, 2023 04:51
@soutaro soutaro added this to the RBS 3.3 milestone Oct 31, 2023
@soutaro soutaro added the Released PRs already included in the released version label Oct 31, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Released PRs already included in the released version
Development

Successfully merging this pull request may close these issues.

2 participants