mirror of
https://github.com/Cornelicorn/bullet-train.zsh.git
synced 2025-12-06 20:00:38 +01:00
Added ability to hide username or hostname
This commit is contained in:
@@ -58,6 +58,12 @@ If you don't want to display your username (the green or red (root) colors are s
|
|||||||
POWERLINE_HIDE_USER_NAME="true"
|
POWERLINE_HIDE_USER_NAME="true"
|
||||||
```
|
```
|
||||||
|
|
||||||
|
If you don't want to display your hostname (the green or red (root) colors are still there):
|
||||||
|
|
||||||
|
```
|
||||||
|
POWERLINE_HIDE_HOST_NAME="true"
|
||||||
|
```
|
||||||
|
|
||||||
If you don't want the blank line before the prompt:
|
If you don't want the blank line before the prompt:
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|||||||
@@ -14,7 +14,11 @@ else
|
|||||||
POWERLINE_RIGHT_A=""
|
POWERLINE_RIGHT_A=""
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$POWERLINE_HIDE_USER_NAME" = "" ]; then
|
if [ "$POWERLINE_HIDE_USER_NAME" = "" ] && [ "$POWERLINE_HIDE_HOST_NAME" = "" ]; then
|
||||||
|
POWERLINE_USER_NAME="%n@%M"
|
||||||
|
elif [ "$POWERLINE_HIDE_USER_NAME" != "" ] && [ "$POWERLINE_HIDE_HOST_NAME" = "" ]; then
|
||||||
|
POWERLINE_USER_NAME="@%M"
|
||||||
|
elif [ "$POWERLINE_HIDE_USER_NAME" = "" ] && [ "$POWERLINE_HIDE_HOST_NAME" != "" ]; then
|
||||||
POWERLINE_USER_NAME="%n"
|
POWERLINE_USER_NAME="%n"
|
||||||
else
|
else
|
||||||
POWERLINE_USER_NAME=""
|
POWERLINE_USER_NAME=""
|
||||||
|
|||||||
Reference in New Issue
Block a user