mirror of
https://github.com/Steffo99/config-fish.git
synced 2024-12-22 23:04:22 +00:00
Change prompt username coloring
This commit is contained in:
parent
b6202a3f67
commit
699f8f9988
1 changed files with 7 additions and 6 deletions
|
@ -5,18 +5,19 @@ function fish_prompt
|
||||||
|
|
||||||
|
|
||||||
# User name
|
# User name
|
||||||
if test "$UID" -eq 0
|
switch ~
|
||||||
|
case "/root/"
|
||||||
# Root
|
# Root
|
||||||
set_color brred
|
set_color brred
|
||||||
else if test "$UID" -lt 1000
|
case "/srv/*"
|
||||||
# System account
|
# System account
|
||||||
set_color brpurple
|
set_color brpurple
|
||||||
else if test "$UID" -ge 60000
|
case "/home/*"
|
||||||
# Temporary account
|
|
||||||
set_color brcyan
|
|
||||||
else
|
|
||||||
# Regular user
|
# Regular user
|
||||||
set_color brgreen
|
set_color brgreen
|
||||||
|
case "*"
|
||||||
|
# Temporary account
|
||||||
|
set_color brcyan
|
||||||
end
|
end
|
||||||
echo -n "$USER"
|
echo -n "$USER"
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue