-
-
Notifications
You must be signed in to change notification settings - Fork 960
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 options to change secondary and/or root prompt chars #461
Conversation
This change allows users to decide if they want a different character for the secondary prompt and for the root user. This is achieved with the variables `SPACESHIP_CHAR_SYMBOL_ROOT`, which is used in place of the default char symbol if the current UID is 0, and `SPACESHIP_CHAR_SYMBOL_SECONDARY`, which is used instead of the default char for the PS2 prompt.
Thanks @Darkhogg for PR. Let me try to address these changes from my perspective,
So I would not favor this changes, But leaving this open for more discussion. |
Let me address your points specifically:
As an "extremely customizable theme" (direct quote from the README), the ability to select how you want the prompt characters to look I think is a basic one, especially when it's something most shells already do out of the box. It's ok if you don't agree, but know that there's at least one user (me) that's using a fork instead of upstream primarily so these customizations are available. |
I think it's an interesting PR and is worth merging, one scenario where this would be useful is copy-paste, where colors are lost, but everyone is familiar with the conventional meaning of chars |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
We try to find the balance between being customizable and not to confuse users with too many options. That's why we try to think twice before adding new options and sections.
Thanks @maximbaz, Didn't immediately think of that. |
Thank you for contributing @Darkhogg |
Description
Add two config variables to control the prompt character for secondary prompts and for the root user:
SPACESHIP_CHAR_SYMBOL_ROOT
to change the root promptSPACESHIP_CHAR_SYMBOL_SECONDARY
to change the seondary promptBoth default to
$SPACESHIP_CHAR_SYMBOL
, so this change should not alter the current behaviour and not affect any users that don't change those vars.Screenshot
With the following config:
I get the following prompts
(I also have all of them configured with the same color, but otherwise the regular color configuration is maintained)