summaryrefslogtreecommitdiff
path: root/.config/fish/functions/_tide_item_context.fish
diff options
context:
space:
mode:
authorRoger Gonzalez <roger@rogs.me>2023-03-18 16:40:57 -0300
committerRoger Gonzalez <roger@rogs.me>2023-03-18 16:40:57 -0300
commit8600374371f91843064441113f4023cda1730877 (patch)
treebb4677ec186dd5c323f1f010207076b7df285606 /.config/fish/functions/_tide_item_context.fish
parentc95dd49df12f4f8dc13cf3bdc4dad70a060bd5eb (diff)
General fish fixes and updates
Diffstat (limited to '.config/fish/functions/_tide_item_context.fish')
-rw-r--r--.config/fish/functions/_tide_item_context.fish9
1 files changed, 9 insertions, 0 deletions
diff --git a/.config/fish/functions/_tide_item_context.fish b/.config/fish/functions/_tide_item_context.fish
new file mode 100644
index 00000000..9dfa56d7
--- /dev/null
+++ b/.config/fish/functions/_tide_item_context.fish
@@ -0,0 +1,9 @@
+function _tide_item_context
+ if set -q SSH_TTY
+ tide_context_color=$tide_context_color_ssh _tide_print_item context $USER@$hostname
+ else if test "$EUID" = 0
+ tide_context_color=$tide_context_color_root _tide_print_item context $USER@$hostname
+ else if test "$tide_context_always_display" = true
+ tide_context_color=$tide_context_color_default _tide_print_item context $USER@$hostname
+ end
+end