problem:
1) Kubernetes contexts does not have to be in a certain namespace, especially for macs. This is the result below.
2) Kubernetes commands output strings which causes the prompt to return multiples of the same string since they are obtained with the command command and then used to set the prompt. See below
With the proposed fix, the checks are dependent on files existing first, then setting the prompt for kubernetes context. As for kubernetes namespace, with the proposed fix, can be empty if need be.
problem: 1) Kubernetes contexts does not have to be in a certain namespace, especially for macs. This is the result below.
2) Kubernetes commands output strings which causes the prompt to return multiples of the same string since they are obtained with the command command and then used to set the prompt. See below
With the proposed fix, the checks are dependent on files existing first, then setting the prompt for kubernetes context. As for kubernetes namespace, with the proposed fix, can be empty if need be.
This is with everything fixed: