mirror of
https://github.com/IlanCosman/tide.git
synced 2024-12-23 20:13:05 +03:00
Minor edits
This commit is contained in:
parent
338800f621
commit
73c7dc2c25
@ -1,5 +1,4 @@
|
|||||||
function _tide_print_item -a item
|
function _tide_print_item -a item
|
||||||
itemColorName=tide_"$item"_color set itemColor $$itemColorName
|
|
||||||
itemBgColorName=tide_"$item"_bg_color set itemBgColor $$itemBgColorName
|
itemBgColorName=tide_"$item"_bg_color set itemBgColor $$itemBgColorName
|
||||||
|
|
||||||
if test "$_tide_which_side_working_on" = left
|
if test "$_tide_which_side_working_on" = left
|
||||||
@ -28,7 +27,7 @@ function _tide_print_item -a item
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
set_color $itemColor -b $itemBgColor
|
itemColorName=tide_"$item"_color set_color $$itemColorName -b $itemBgColor
|
||||||
|
|
||||||
if test "$tide_prompt_pad_items" = true -a "$item" != character
|
if test "$tide_prompt_pad_items" = true -a "$item" != character
|
||||||
printf '%s' ' ' $argv[2..] ' '
|
printf '%s' ' ' $argv[2..] ' '
|
||||||
|
@ -2,7 +2,7 @@ function _tide_prompt
|
|||||||
# Variables are exported as strings, convert _tide_last_pipestatus back into a list
|
# Variables are exported as strings, convert _tide_last_pipestatus back into a list
|
||||||
set -g _tide_last_pipestatus (string split ' ' $_tide_last_pipestatus)
|
set -g _tide_last_pipestatus (string split ' ' $_tide_last_pipestatus)
|
||||||
|
|
||||||
test "$tide_prompt_add_newline_before" = true && printf '%b' '\n'
|
test "$tide_prompt_add_newline_before" = true && echo
|
||||||
|
|
||||||
set -l leftPrompt (_tide_left_prompt)
|
set -l leftPrompt (_tide_left_prompt)
|
||||||
set -l leftPromptHeight (count $leftPrompt)
|
set -l leftPromptHeight (count $leftPrompt)
|
||||||
@ -23,7 +23,6 @@ function _tide_prompt
|
|||||||
printf '%s' $leftPrompt[1]
|
printf '%s' $leftPrompt[1]
|
||||||
|
|
||||||
set_color $tide_prompt_connection_color
|
set_color $tide_prompt_connection_color
|
||||||
test -n "$tide_prompt_connection_icon" || set -l tide_prompt_connection_icon ' '
|
|
||||||
set -l lengthToMove (math $COLUMNS - (_tide_decolor "$leftPrompt[1]""$rightPrompt[1]" | string length))
|
set -l lengthToMove (math $COLUMNS - (_tide_decolor "$leftPrompt[1]""$rightPrompt[1]" | string length))
|
||||||
test $lengthToMove -gt 0 && string repeat --no-newline --max $lengthToMove $tide_prompt_connection_icon
|
test $lengthToMove -gt 0 && string repeat --no-newline --max $lengthToMove $tide_prompt_connection_icon
|
||||||
|
|
||||||
@ -42,7 +41,7 @@ function _tide_left_prompt
|
|||||||
_tide_item_$item
|
_tide_item_$item
|
||||||
end
|
end
|
||||||
|
|
||||||
if test "$tide_last_item" != newline -a "$tide_last_item" != character
|
if not contains -- $tide_last_item newline character
|
||||||
set_color $tide_previous_bg_color -b normal
|
set_color $tide_previous_bg_color -b normal
|
||||||
printf '%s' $tide_left_prompt_suffix
|
printf '%s' $tide_left_prompt_suffix
|
||||||
end
|
end
|
||||||
|
@ -2,7 +2,7 @@ function prompt_connection
|
|||||||
_tide_title 'Prompt Connection'
|
_tide_title 'Prompt Connection'
|
||||||
|
|
||||||
_tide_option 1 Disconnected
|
_tide_option 1 Disconnected
|
||||||
_tide_display_prompt fake_tide_prompt_connection_icon ''
|
_tide_display_prompt fake_tide_prompt_connection_icon ' '
|
||||||
|
|
||||||
_tide_option 2 Dotted
|
_tide_option 2 Dotted
|
||||||
_tide_display_prompt fake_tide_prompt_connection_icon '·'
|
_tide_display_prompt fake_tide_prompt_connection_icon '·'
|
||||||
@ -13,7 +13,7 @@ function prompt_connection
|
|||||||
_tide_menu
|
_tide_menu
|
||||||
switch $_tide_selected_option
|
switch $_tide_selected_option
|
||||||
case 1
|
case 1
|
||||||
set -g fake_tide_prompt_connection_icon ''
|
set -g fake_tide_prompt_connection_icon ' '
|
||||||
case 2
|
case 2
|
||||||
set -g fake_tide_prompt_connection_icon '·'
|
set -g fake_tide_prompt_connection_icon '·'
|
||||||
case 3
|
case 3
|
||||||
|
@ -50,7 +50,7 @@ tide_php_color 875FFF
|
|||||||
tide_php_icon ''
|
tide_php_icon ''
|
||||||
tide_prompt_add_newline_before true
|
tide_prompt_add_newline_before true
|
||||||
tide_prompt_connection_color 6C6C6C
|
tide_prompt_connection_color 6C6C6C
|
||||||
tide_prompt_connection_icon ''
|
tide_prompt_connection_icon ' '
|
||||||
tide_prompt_pad_items true
|
tide_prompt_pad_items true
|
||||||
tide_pwd_bg_color 444444
|
tide_pwd_bg_color 444444
|
||||||
tide_pwd_color_anchors $_tide_color_light_blue
|
tide_pwd_color_anchors $_tide_color_light_blue
|
||||||
|
@ -51,7 +51,7 @@ tide_php_color 875FFF
|
|||||||
tide_php_icon ''
|
tide_php_icon ''
|
||||||
tide_prompt_add_newline_before true
|
tide_prompt_add_newline_before true
|
||||||
tide_prompt_connection_color 6C6C6C
|
tide_prompt_connection_color 6C6C6C
|
||||||
tide_prompt_connection_icon ''
|
tide_prompt_connection_icon ' '
|
||||||
tide_prompt_pad_items false
|
tide_prompt_pad_items false
|
||||||
tide_pwd_bg_color normal
|
tide_pwd_bg_color normal
|
||||||
tide_pwd_color_anchors $_tide_color_light_blue
|
tide_pwd_color_anchors $_tide_color_light_blue
|
||||||
|
@ -51,7 +51,7 @@ tide_php_color 000000
|
|||||||
tide_php_icon ''
|
tide_php_icon ''
|
||||||
tide_prompt_add_newline_before true
|
tide_prompt_add_newline_before true
|
||||||
tide_prompt_connection_color 6C6C6C
|
tide_prompt_connection_color 6C6C6C
|
||||||
tide_prompt_connection_icon ''
|
tide_prompt_connection_icon ' '
|
||||||
tide_prompt_pad_items true
|
tide_prompt_pad_items true
|
||||||
tide_pwd_bg_color 3465A4
|
tide_pwd_bg_color 3465A4
|
||||||
tide_pwd_color_anchors E4E4E4
|
tide_pwd_color_anchors E4E4E4
|
||||||
|
Loading…
Reference in New Issue
Block a user