add files
This commit is contained in:
commit
40b77f88ea
20 changed files with 522 additions and 0 deletions
21
fish/functions/fish_prompt.fish
Executable file
21
fish/functions/fish_prompt.fish
Executable file
|
@ -0,0 +1,21 @@
|
|||
function fish_prompt
|
||||
# This is a simple prompt. It looks like
|
||||
# alfa@nobby /path/to/dir $
|
||||
# with the path shortened and colored
|
||||
# and a "#" instead of a "$" when run as root.
|
||||
set -l symbol ' $ '
|
||||
set -l color $fish_color_cwd
|
||||
if fish_is_root_user
|
||||
set symbol ' # '
|
||||
set -q fish_color_cwd_root
|
||||
and set color $fish_color_cwd_root
|
||||
end
|
||||
|
||||
echo -n $USER@$hostname
|
||||
|
||||
set_color $color
|
||||
echo -n (prompt_pwd)
|
||||
set_color normal
|
||||
|
||||
echo -n $symbol
|
||||
end
|
Loading…
Add table
Add a link
Reference in a new issue