Different prompt for remote shells

This commit is contained in:
hoellen 2020-06-20 15:20:01 +02:00
parent 60dc13d1de
commit 558fbda30c

View File

@ -79,11 +79,19 @@ function fish_prompt
set arrow_color "$red" set arrow_color "$red"
end end
set -l arrow "$arrow_color" set -l arrow_user "$arrow_color"
if test "$USER" = 'root' if test "$USER" = 'root'
set arrow "$arrow_color# " set -e arrow_user
set arrow_root "$arrow_color#"
end end
if set -q SSH_CLIENT || set -q SSH_TTY
set -e arrow_user
set arrow "$blue🌍"
end
set -l arrow "$arrow$arrow_user$arrow_root"
set -l cwd $cyan(basename (prompt_pwd)) set -l cwd $cyan(basename (prompt_pwd))
if set -l repo_type (_repo_type) if set -l repo_type (_repo_type)