From 68c028eea66c6ca7bbc03e6979f26ffd6b8c6106 Mon Sep 17 00:00:00 2001 From: Ilan Cosman Date: Mon, 26 Apr 2021 13:27:02 -0700 Subject: [PATCH] minor edits --- functions/_tide_print_item.fish | 13 +++++++------ functions/_tide_right_prompt.fish | 2 +- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/functions/_tide_print_item.fish b/functions/_tide_print_item.fish index d2f0de3..6849102 100644 --- a/functions/_tide_print_item.fish +++ b/functions/_tide_print_item.fish @@ -17,10 +17,8 @@ function _tide_print_item -a item end else if test "$tide_last_item" = newline - if test "$item" != character - set_color $itemBgColor -b normal - printf '%s' $tide_right_prompt_prefix - end + set_color $itemBgColor -b normal + printf '%s' $tide_right_prompt_prefix else if test "$itemBgColor" = "$tide_previous_bg_color" set_color $tide_right_prompt_item_separator_same_color_color printf '%s' $tide_right_prompt_item_separator_same_color @@ -32,8 +30,11 @@ function _tide_print_item -a item set_color $itemColor -b $itemBgColor - test "$tide_prompt_pad_items" = true -a "$item" != character && set -l padItem ' ' - itemIconName=tide_"$item"_icon printf '%s' $padItem $$itemIconName' ' $argv[2..] $padItem + if test "$tide_prompt_pad_items" = true -a "$item" != character + itemIconName=tide_"$item"_icon printf '%s' ' ' $$itemIconName' ' $argv[2..] ' ' + else + itemIconName=tide_"$item"_icon printf '%s' $$itemIconName' ' $argv[2..] + end set -g tide_previous_bg_color $itemBgColor set -g tide_last_item $item diff --git a/functions/_tide_right_prompt.fish b/functions/_tide_right_prompt.fish index 6895c86..c3ed8dc 100644 --- a/functions/_tide_right_prompt.fish +++ b/functions/_tide_right_prompt.fish @@ -12,7 +12,7 @@ function _tide_right_prompt end end - if test "$tide_last_item" != newline -a "$tide_last_item" != character + if test "$tide_last_item" != newline set_color $tide_previous_bg_color -b normal printf '%s' $tide_right_prompt_suffix end