jonmosco / kube-ps1

Kubernetes prompt info for bash and zsh
Apache License 2.0
3.52k stars 351 forks source link

Hide no cluster and default namespace option #177

Closed giautm closed 7 months ago

giautm commented 1 year ago

Hello, I would like to have a built-in flag to disable display kube_ps1 result for unset context and default. For now, I used both KUBE_PS1_CLUSTER_FUNCTION and KUBE_PS1_NAMESPACE_FUNCTION to do that as in my theme

But it's more easy if we can disable just via an env. Thank you,

Screenshot 2023-07-21 at 11 02 35
jonmosco commented 9 months ago

Have you looked at the kubeon and kubeoff functions? https://github.com/jonmosco/kube-ps1?tab=readme-ov-file#enablingdisabling

jonmosco commented 7 months ago

Functionality provided by the builtin kube{on,off} functions.