49 lines
1.0 KiB
Fish

# Minimaline theme
# A minimal Powerline-style prompt
# Dependency: https://git.candifloss.cc/candifloss/PrettyPrompt
function fish_prompt
set -l exit_status $status
# Colours
set -l bg1 44bfaa
set -l fg1 232323
set -l bg2 171717
set -l bg3 272727
# Set status colour
if test $exit_status -ne 0
set bg3 d64444
end
# Prompt symbol
set -l prompt_symbol '$'
if fish_is_root_user
set prompt_symbol '#'
end
# Segment 1: User@Host
set_color --background $bg1 --bold $fg1
printf " %s@%s " "$USER" (prompt_hostname)
# Separator 1
set_color --background $bg2 $bg1
#set_color $bg1
printf " "
# Segment 2: Current directory
# prettyprompt-pwd handles its own foreground colour
prettyprompt-pwd
# End separators
set_color --background $bg2
printf " "
set_color --background $bg3 $bg2
printf ""
set_color --background normal $bg3
printf ""
# Reset and add trailing space
set_color normal
printf " "
end