2020-05-20 20:05:33 +03:00
|
|
|
function _tide_item_status
|
2020-06-06 21:57:43 +03:00
|
|
|
if string match -q --invert '0' $_tide_last_pipestatus
|
|
|
|
set -l fishPipestatusWithSignal (__fish_pipestatus_with_signal $_tide_last_pipestatus)
|
2020-05-13 22:46:42 +03:00
|
|
|
|
2020-06-06 21:57:43 +03:00
|
|
|
if test (count $_tide_last_pipestatus) -gt 1 || string match -qe 'SIG' $fishPipestatusWithSignal
|
|
|
|
if test $_tide_last_status -eq 0
|
2020-05-19 06:03:25 +03:00
|
|
|
set_color $tide_status_success_color
|
|
|
|
printf '%s ' {$tide_status_success_icon}
|
2020-05-13 22:46:42 +03:00
|
|
|
else
|
2020-05-19 06:03:25 +03:00
|
|
|
set_color $tide_status_failure_color
|
|
|
|
printf '%s ' {$tide_status_failure_icon}
|
2020-05-13 22:46:42 +03:00
|
|
|
end
|
2020-06-10 19:18:15 +03:00
|
|
|
string replace 'SIG' '' $fishPipestatusWithSignal | string join '|'
|
2020-05-13 22:46:42 +03:00
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|