From ed896b65c3ddbdf2929c38719adfb940b0d9b90d Mon Sep 17 00:00:00 2001 From: "Taylor \"Nekroze\" Lawson" Date: Mon, 8 May 2023 12:42:24 +1000 Subject: [PATCH] Fix error when k8s context defined but namespace isn't (#343) Fixed simple mistake of not double qouting namespace so when empty -z consumed -o as its input. --- functions/fish_prompt.fish | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/functions/fish_prompt.fish b/functions/fish_prompt.fish index 21058ea..4651743 100644 --- a/functions/fish_prompt.fish +++ b/functions/fish_prompt.fish @@ -637,8 +637,8 @@ function __bobthefish_prompt_k8s_context -S -d 'Show current Kubernetes context' [ "$theme_display_k8s_namespace" = 'yes' ] and set -l namespace (__bobthefish_k8s_namespace) - [ -z $context -o "$context" = 'default' ] - and [ -z $namespace -o "$namespace" = 'default' ] + [ -z "$context" -o "$context" = 'default' ] + and [ -z "$namespace" -o "$namespace" = 'default' ] and return set -l segment $k8s_glyph ' '