gistfile1.txt
· 492 B · Text
Eredeti
function ui::peer::status_color() {
echo "\033[2;31m" # dim red — blocked offline
echo "\033[2;33m" # dim yellow — restricted offline
echo "\033[2m" # dim gray — plain offline
local status_color
status_color=$(ui::peer::status_color "$is_blocked" "$is_restricted" "$status")
# Colored row — entire row in row_color, status uses status_color
"$status_color" "$status_pad" \
"$status_color" "$ts_pad"
"$status_color" "$status_pad" \
| 1 | function ui::peer::status_color() { |
| 2 | echo "\033[2;31m" # dim red — blocked offline |
| 3 | echo "\033[2;33m" # dim yellow — restricted offline |
| 4 | echo "\033[2m" # dim gray — plain offline |
| 5 | local status_color |
| 6 | status_color=$(ui::peer::status_color "$is_blocked" "$is_restricted" "$status") |
| 7 | # Colored row — entire row in row_color, status uses status_color |
| 8 | "$status_color" "$status_pad" \ |
| 9 | "$status_color" "$ts_pad" |
| 10 | "$status_color" "$status_pad" \ |
| 11 |