1
Fork 0
mirror of https://github.com/Steffo99/config-fish.git synced 2024-12-22 14:54:23 +00:00

Change detections

This commit is contained in:
Steffo 2022-09-27 00:04:46 +02:00
parent 84d68eeb4a
commit 78ef972de7
Signed by: steffo
GPG key ID: 6965406171929D01

View file

@ -9,15 +9,12 @@ function fish_prompt
case "/root" case "/root"
# Root # Root
set_color brred set_color brred
case "/srv/*"
# System account
set_color brpurple
case "/home/*" case "/home/*"
# Regular user # Regular user
set_color brgreen set_color brgreen
case "*" case "*"
# Temporary account # Temporary account
set_color brcyan set_color brpurple
end end
echo -n "$USER" echo -n "$USER"
@ -36,10 +33,12 @@ function fish_prompt
# Hostname # Hostname
if test -z "$SSH_CLIENT" if test -n "$SSH_CLIENT"
set_color green
else
set_color cyan set_color cyan
else if test -n "$SUDO_COMMAND"
set_color purple
else
set_color green
end end
echo -n (prompt_hostname) echo -n (prompt_hostname)