kubeswitch icon indicating copy to clipboard operation
kubeswitch copied to clipboard

support fish shell?

Open sandangel opened this issue 2 years ago • 5 comments

Hi, is it possible to also support fish shell?

sandangel avatar Jun 10 '22 04:06 sandangel

Hi, yep it is certainly possible. It is just that I am not a fish user so I have not added it so far. In case someone wants to contribute that, feel welcome :)

danielfoehrKn avatar Jun 13 '22 20:06 danielfoehrKn

@danielfoehrKn hi, could you let me know what should be done to add support for fish shell?

sandangel avatar Jun 14 '22 04:06 sandangel

Central to kubeswitch is the switch.sh script here that calls the switcher binary. The script has a proper bash shebang, so it might just work under fish. I think the first step is to try to use kubeswitch using the fish shell and see if something does not work.

danielfoehrKn avatar Jun 14 '22 07:06 danielfoehrKn

@danielfoehrKn I don't think it will work, because we are calling the switch function in that script, not the script itself.

sandangel avatar Jun 14 '22 08:06 sandangel

I also suspect that it will only set the environment variable for KUBECONFIG file inside the bash shell itself, not all shells.

sandangel avatar Jun 14 '22 08:06 sandangel