-
-
Notifications
You must be signed in to change notification settings - Fork 972
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 support for custom prompt arrow color #256
Conversation
👍 |
What would you set those options to? Just curious. |
For me it'd be green for success and red for fail. It goes better with the color scheme I am using right now. |
@sindresorhus Rather than Because magenta/red combo don't have enough color contrast. |
We get a few requests for modifying the colors (and symbols, etc) of Pure through options every now and a then. The reason we do not accept them is that we don't want to clutter pure with options. Ideally Pure would have even less options than it does currently. It's actually possible to override the In my opinion, merging this PR would mean that we need to embrace full custom colorization of the prompt. This in turn means new options or an alternate method of defining the colors. I also don't mean to be disrespecting of any level of color blindness, but if I had a problem telling the colors apart, I would change them in my terminal so that they are more so (no reason to keep magenta as magenta). All this being said, I have no strong preference on the default promt color(s). Logically green/red makes most sense, but I took a liking to magenta after using it with Pure (as @sindresorhus intended 😝). PS. Entertaining that this PR would be merged, I think variable names should not be |
I appreciate your feedback @mafredri. My goal was to simply contribute back a minor change I had made, in case others wanted to enjoy the same benefits. And since the prompt character itself (the arrow) was open to customization via variables, I took the same approach to customize the colors of said character. |
The variable names of |
If the maintainer thinks this PR is a good contribution, I can update the environment variables to |
I have a VERY difficult time differentiating between the magenta and red colors, especially when they are represented by a single character. If this PR is not accepted, then please consider using a different color other than magenta for "return value OK". |
Would like to see this being implemented, too! I also have a hard time to distinguish between magenta and red and I believe form should follow function here! |
I fixed the merge conflicts on this PR. |
For what it's worth, I've been running with this patch for over a year now, on several systems, and have had 0 problems. Being able to set the color to something that is easier to distinguish from the red arrow prompt is great. Thank you @petermbenjamin, I hope this gets merged so that others can benefit! |
Closing this in favor of #472. |
Feature
Support custom prompt arrow color when commands complete or fail.
This can be controlled via the following options:
PURE_PROMPT_COLOR_NORMAL
andPURE_PROMPT_COLOR_FAIL
Reasoning
magenta
) and the default color for failed commands (red
).red
andmagenta
appear as the same color.