mirror of
https://github.com/oh-my-fish/theme-bobthefish.git
synced 2025-06-13 13:03:54 +00:00
Move Kubernetes prompt color into a function
This commit is contained in:
parent
626bd39b00
commit
864a50c42e
5
functions/__bobthefish_prompt_k8s_color.fish
Normal file
5
functions/__bobthefish_prompt_k8s_color.fish
Normal file
@ -0,0 +1,5 @@
|
||||
function __bobthefish_prompt_k8s_color -S -d 'Determine Kubernetes prompt color based on the current context and namespace'
|
||||
for i in $color_k8s
|
||||
echo $i
|
||||
end
|
||||
end
|
@ -645,11 +645,10 @@ function __bobthefish_prompt_k8s_context -S -d 'Show current Kubernetes context'
|
||||
[ -n "$namespace" ]
|
||||
and set segment $segment ':' $namespace
|
||||
|
||||
__bobthefish_start_segment $color_k8s
|
||||
__bobthefish_start_segment (__bobthefish_prompt_k8s_color $context $namespace)
|
||||
echo -ns $segment ' '
|
||||
end
|
||||
|
||||
|
||||
# ==============================
|
||||
# Cloud Tools
|
||||
# ==============================
|
||||
|
Loading…
Reference in New Issue
Block a user