diff --git a/fish_prompt.fish b/fish_prompt.fish index 4c47f7f..bde6c49 100644 --- a/fish_prompt.fish +++ b/fish_prompt.fish @@ -35,6 +35,7 @@ # set -g theme_display_ruby no # set -g theme_display_user ssh # set -g theme_display_hostname ssh +# set -g theme_display_screen no # set -g theme_display_sudo_user yes # set -g theme_display_vi no # set -g theme_display_nvm yes @@ -911,6 +912,18 @@ function __bobthefish_prompt_hg -S -a hg_root_dir -a real_pwd -d 'Display the ac end end +function __bobthefish_prompt_screen -S -d 'Display the screen name' + [ "$theme_display_screen" != 'yes' ] + and return + + [ -z "$STY" ] + and return + + __bobthefish_start_segment $color_screen + echo -ns (command echo $STY | cut -d. -f2) ' ' + set_color normal +end + function __bobthefish_prompt_git -S -a git_root_dir -a real_pwd -d 'Display the actual git state' set -l dirty '' if [ "$theme_display_git_dirty" != 'no' ] @@ -1064,6 +1077,7 @@ function fish_prompt -d 'bobthefish, a fish theme optimized for awesome' # User / hostname info __bobthefish_prompt_user + __bobthefish_prompt_screen # Containers and VMs __bobthefish_prompt_vagrant diff --git a/functions/__bobthefish_colors.fish b/functions/__bobthefish_colors.fish index 93be762..e87eeca 100644 --- a/functions/__bobthefish_colors.fish +++ b/functions/__bobthefish_colors.fish @@ -29,6 +29,7 @@ function __bobthefish_colors -S -a color_scheme -d 'Define colors used by bobthe set -x color_k8s magenta white --bold set -x color_username white black --bold set -x color_hostname white black + set -x color_screen brgreen $colorfg set -x color_rvm brmagenta $colorfg --bold set -x color_nvm brgreen $colorfg --bold set -x color_virtualfish brblue $colorfg --bold @@ -61,6 +62,7 @@ function __bobthefish_colors -S -a color_scheme -d 'Define colors used by bobthe set -x color_k8s magenta white --bold set -x color_username black white --bold set -x color_hostname black white + set -x color_screen brgreen $colorfg set -x color_rvm brmagenta $colorfg --bold set -x color_nvm brgreen $colorfg --bold set -x color_virtualfish brblue $colorfg --bold @@ -93,6 +95,7 @@ function __bobthefish_colors -S -a color_scheme -d 'Define colors used by bobthe set -x color_k8s magenta white --bold set -x color_username brgrey white --bold set -x color_hostname brgrey white + set -x color_screen brgreen $colorfg set -x color_rvm brmagenta $colorfg --bold set -x color_nvm brgreen $colorfg --bold set -x color_virtualfish brblue $colorfg --bold @@ -125,6 +128,7 @@ function __bobthefish_colors -S -a color_scheme -d 'Define colors used by bobthe set -x color_k8s magenta white --bold set -x color_username grey black --bold set -x color_hostname grey black + set -x color_screen brgreen $colorfg set -x color_rvm brmagenta $colorfg --bold set -x color_nvm brgreen $colorfg --bold set -x color_virtualfish brblue $colorfg --bold @@ -163,6 +167,7 @@ function __bobthefish_colors -S -a color_scheme -d 'Define colors used by bobthe set -x color_k8s $green $white --bold set -x color_username $grey $blue --bold set -x color_hostname $grey $blue + set -x color_screen $green $grey set -x color_rvm $red $grey --bold set -x color_nvm $green $white --bold set -x color_virtualfish $blue $grey --bold @@ -212,6 +217,7 @@ function __bobthefish_colors -S -a color_scheme -d 'Define colors used by bobthe set -x color_k8s $base06 $colorfg --bold set -x color_username $base02 $base0D --bold set -x color_hostname $base02 $base0D + set -x color_screen $base06 $colorfg set -x color_rvm $base08 $colorfg --bold set -x color_nvm $base0B $colorfg --bold set -x color_virtualfish $base0D $colorfg --bold @@ -261,6 +267,7 @@ function __bobthefish_colors -S -a color_scheme -d 'Define colors used by bobthe set -x color_k8s $base0B $colorfg --bold set -x color_username $base02 $base0D --bold set -x color_hostname $base02 $base0D + set -x color_screen $base0B $colorfg set -x color_rvm $base08 $colorfg --bold set -x color_nvm $base0B $colorfg --bold set -x color_virtualfish $base0D $colorfg --bold @@ -310,6 +317,7 @@ function __bobthefish_colors -S -a color_scheme -d 'Define colors used by bobthe set -x color_k8s $green $colorfg --bold set -x color_username $base2 $blue --bold set -x color_hostname $base2 $blue + set -x color_screen $green $colorfg set -x color_rvm $red $colorfg --bold set -x color_nvm $green $colorfg --bold set -x color_virtualfish $cyan $colorfg --bold @@ -359,6 +367,7 @@ function __bobthefish_colors -S -a color_scheme -d 'Define colors used by bobthe set -x color_k8s $green $colorfg --bold set -x color_username $base02 $blue --bold set -x color_hostname $base02 $blue + set -x color_screen $green $colorfg set -x color_rvm $red $colorfg --bold set -x color_nvm $green $colorfg --bold set -x color_virtualfish $cyan $colorfg --bold @@ -401,6 +410,7 @@ function __bobthefish_colors -S -a color_scheme -d 'Define colors used by bobthe set -x color_k8s $green[1] $colorfg --bold set -x color_username $grey[1] $blue[3] --bold set -x color_hostname $grey[1] $blue[3] + set -x color_screen $green[1] $colorfg set -x color_rvm $ruby_red $grey[1] --bold set -x color_nvm $green $grey[1] --bold set -x color_virtualfish $blue[2] $grey[1] --bold @@ -442,6 +452,7 @@ function __bobthefish_colors -S -a color_scheme -d 'Define colors used by bobthe set -x color_k8s $green[2] $fg[2] --bold set -x color_username $fg[3] $blue[2] --bold set -x color_hostname $fg[3] $blue[2] + set -x color_screen $green[1] $fg[2] set -x color_rvm $red[2] $fg[2] --bold set -x color_nvm $green[1] $fg[2] --bold set -x color_virtualfish $blue[2] $fg[2] --bold @@ -485,6 +496,7 @@ function __bobthefish_colors -S -a color_scheme -d 'Define colors used by bobthe set -x color_k8s $green $fg --bold set -x color_username $selection $cyan --bold set -x color_hostname $selection $cyan + set -x color_screen $green $fg set -x color_rvm $red $bg --bold set -x color_nvm $green $bg --bold set -x color_virtualfish $comment $bg --bold @@ -534,6 +546,7 @@ function __bobthefish_colors -S -a color_scheme -d 'Define colors used by bobthe set -x color_k8s $base02 $colorfg --bold set -x color_username $base02 $base0D --bold set -x color_hostname $base02 $base0D + set -x color_screen $base02 $colorfg set -x color_rvm $base09 $colorfg --bold set -x color_nvm $base09 $colorfg --bold set -x color_virtualfish $base09 $colorfg --bold @@ -576,6 +589,7 @@ function __bobthefish_colors -S -a color_scheme -d 'Define colors used by bobthe set -x color_k8s $green[2] $white --bold set -x color_username $grey[1] $blue[3] --bold set -x color_hostname $grey[1] $blue[3] + set -x color_screen $green[1] $white set -x color_rvm $ruby_red $grey[1] --bold set -x color_nvm $green[1] $white --bold set -x color_virtualfish $blue[2] $grey[1] --bold @@ -640,6 +654,7 @@ function __bobthefish_user_color_scheme_deprecated set -x color_vagrant $__color_vagrant set -x color_username $__color_username set -x color_hostname $__color_hostname + set -x color_screen $__color_screen set -x color_rvm $__color_rvm set -x color_virtualfish $__color_virtualfish set -x color_virtualgo $__color_virtualgo