diff --git a/fish_prompt.fish b/fish_prompt.fish index 470d142..5eb0674 100644 --- a/fish_prompt.fish +++ b/fish_prompt.fish @@ -851,6 +851,21 @@ function __bobthefish_prompt_virtualgo -S -d 'Display current Go virtual environ set_color normal end +function __bobthefish_prompt_ranger -S -d 'Display current ranger indicator' + [ "$theme_display_ranger" = 'no' -o -z "$RANGER_LEVEL" ] + and return + + __bobthefish_start_segment $color_ranger + echo -ns $ranger_glyph + + if [ "$theme_display_ranger_level" = 'yes' ] + echo -ns "$RANGER_LEVEL" + end + + echo -ns ' ' + set_color normal +end + function __bobthefish_prompt_desk -S -d 'Display current desk environment' [ "$theme_display_desk" = 'no' -o -z "$DESK_ENV" ] and return @@ -1077,6 +1092,7 @@ function fish_prompt -d 'bobthefish, a fish theme optimized for awesome' __bobthefish_prompt_rubies __bobthefish_prompt_virtualfish __bobthefish_prompt_virtualgo + __bobthefish_prompt_ranger __bobthefish_prompt_nvm set -l real_pwd (__bobthefish_pwd) diff --git a/functions/__bobthefish_glyphs.fish b/functions/__bobthefish_glyphs.fish index 6d82b66..eaaa655 100644 --- a/functions/__bobthefish_glyphs.fish +++ b/functions/__bobthefish_glyphs.fish @@ -21,6 +21,7 @@ function __bobthefish_glyphs -S -d 'Define glyphs used by bobthefish' set -x ruby_glyph '' set -x go_glyph '' + set -x ranger_glyph 'R' # Desk glyphs set -x desk_glyph \u25F2