docs: Update example prompt in fish_prompt docs

This used `whoami` and `hostname` and lacked spaces.

[ci skip]
This commit is contained in:
Fabian Homborg 2020-10-02 19:02:10 +02:00
parent 558dd6e53d
commit 17157b3516

View file

@ -33,7 +33,10 @@ A simple prompt:
::
function fish_prompt -d "Write out the prompt"
printf '%s@%s%s%s%s> ' (whoami) (hostname | cut -d . -f 1) \
# This shows up as USER@HOST /home/user/ >, with the directory colored
# $USER and $hostname are set by fish, so you can just use them
# instead of using `whoami` and `hostname`
printf '%s@%s %s%s%s > ' $USER $hostname \
(set_color $fish_color_cwd) (prompt_pwd) (set_color normal)
end