mirror of
https://github.com/fish-shell/fish-shell.git
synced 2025-03-27 14:45:13 +08:00
Use echo -n instead of printf
- Remove useless comment, because multi-line prompt works good now.
This commit is contained in:
parent
239d43dac4
commit
f56f84c6ac
@ -9,25 +9,24 @@ function fish_prompt --description 'Write out the prompt'
|
|||||||
|
|
||||||
# User
|
# User
|
||||||
set_color $fish_color_user
|
set_color $fish_color_user
|
||||||
printf (whoami)
|
echo -n (whoami)
|
||||||
set_color normal
|
set_color normal
|
||||||
|
|
||||||
echo -n '@'
|
echo -n '@'
|
||||||
|
|
||||||
# Host
|
# Host
|
||||||
set_color $fish_color_host
|
set_color $fish_color_host
|
||||||
printf (hostname -s)
|
echo -n (hostname -s)
|
||||||
set_color normal
|
set_color normal
|
||||||
|
|
||||||
echo -n ':'
|
echo -n ':'
|
||||||
|
|
||||||
# PWD
|
# PWD
|
||||||
set_color $fish_color_cwd
|
set_color $fish_color_cwd
|
||||||
printf (prompt_pwd)
|
echo -n (prompt_pwd)
|
||||||
set_color normal
|
set_color normal
|
||||||
|
|
||||||
__terlar_git_prompt
|
__terlar_git_prompt
|
||||||
# I prefer to have a new-line here but messes with the prompt when resizing
|
|
||||||
echo
|
echo
|
||||||
|
|
||||||
if not test $last_status -eq 0
|
if not test $last_status -eq 0
|
||||||
|
Loading…
x
Reference in New Issue
Block a user