From 4f24946d23c77f4710a4d1b31e5761fbcf3bb514 Mon Sep 17 00:00:00 2001 From: winston Date: Thu, 7 Mar 2024 13:41:11 +0100 Subject: [PATCH] feat(k8s): reenable client config --- home/apps/kubernetes.nix | 11 ++++++++++- home/apps/zsh.nix | 2 +- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/home/apps/kubernetes.nix b/home/apps/kubernetes.nix index eac1d52..2068454 100644 --- a/home/apps/kubernetes.nix +++ b/home/apps/kubernetes.nix @@ -12,7 +12,6 @@ gojq jqp konf - krew kubecolor kubeconform kubectl @@ -27,6 +26,16 @@ velero ]; + programs.zsh.initExtra = '' + # kubecolor + compdef kubecolor=kubectl + # konf + source <(konf-go shellwrapper zsh) + source <(konf completion zsh) + # ignore if konf store hasn't been initialized + konf set - >/dev/null 2>&1 + ''; + home.shellAliases = { jq = "gojq"; kcn = "konf ns"; diff --git a/home/apps/zsh.nix b/home/apps/zsh.nix index f495f9c..fc84228 100644 --- a/home/apps/zsh.nix +++ b/home/apps/zsh.nix @@ -151,7 +151,7 @@ in { oh-my-zsh = { enable = true; plugins = - ["colored-man-pages" "colorize" "git"] + ["colored-man-pages" "colorize" "git" "kubectl"] ++ lib.optionals pkgs.stdenv.isDarwin ["dash" "macos"]; }; plugins = zshPlugins [