From eccbebc502159e248987874c8e0b47dd758bea3a Mon Sep 17 00:00:00 2001 From: Denis Salamanca <33235720+dsalamancaMS@users.noreply.github.com> Date: Thu, 7 Jun 2018 12:13:40 -0600 Subject: [PATCH 1/4] Update with tab completion for kubectl Update with tab completion for kubectl --- docs/02-client-tools.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/docs/02-client-tools.md b/docs/02-client-tools.md index 7f0a2a0..d23605c 100644 --- a/docs/02-client-tools.md +++ b/docs/02-client-tools.md @@ -99,6 +99,13 @@ chmod +x kubectl ``` sudo mv kubectl /usr/local/bin/ ``` +The following steps will enable shell tab completion on kubectl while using bash: + +``` +echo "source <(kubectl completion bash)" >> ~/.bashrc && bash +``` +>You can also omit the "&& bash" and reload the shell later. +>This will only enable tab completion for your current user. ### Verification From c287801a5b199bcfcd34d7d6641c0a7f67222d55 Mon Sep 17 00:00:00 2001 From: Denis Salamanca <33235720+dsalamancaMS@users.noreply.github.com> Date: Sun, 10 Jun 2018 22:12:25 -0600 Subject: [PATCH 2/4] changed to reload .bashrc Changed from spawning a new shell to reloading .bashrc --- docs/02-client-tools.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/02-client-tools.md b/docs/02-client-tools.md index d23605c..7699d2f 100644 --- a/docs/02-client-tools.md +++ b/docs/02-client-tools.md @@ -102,7 +102,7 @@ sudo mv kubectl /usr/local/bin/ The following steps will enable shell tab completion on kubectl while using bash: ``` -echo "source <(kubectl completion bash)" >> ~/.bashrc && bash +echo "source <(kubectl completion bash)" >> ~/.bashrc && .~/.bashrc ``` >You can also omit the "&& bash" and reload the shell later. >This will only enable tab completion for your current user. From 52f14d747d952de538b0d4e9d09a7a525c5a0c50 Mon Sep 17 00:00:00 2001 From: Denis Salamanca <33235720+dsalamancaMS@users.noreply.github.com> Date: Mon, 11 Jun 2018 10:13:29 -0600 Subject: [PATCH 3/4] added missing space on ". ~/.bashrc" --- docs/02-client-tools.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/02-client-tools.md b/docs/02-client-tools.md index 7699d2f..0f28669 100644 --- a/docs/02-client-tools.md +++ b/docs/02-client-tools.md @@ -102,7 +102,7 @@ sudo mv kubectl /usr/local/bin/ The following steps will enable shell tab completion on kubectl while using bash: ``` -echo "source <(kubectl completion bash)" >> ~/.bashrc && .~/.bashrc +echo "source <(kubectl completion bash)" >> ~/.bashrc && . ~/.bashrc ``` >You can also omit the "&& bash" and reload the shell later. >This will only enable tab completion for your current user. From e5e10c4c04448bc9e42565e2b9541958f6066192 Mon Sep 17 00:00:00 2001 From: Denis Salamanca <33235720+dsalamancaMS@users.noreply.github.com> Date: Mon, 11 Jun 2018 10:24:58 -0600 Subject: [PATCH 4/4] Update 02-client-tools.md --- docs/02-client-tools.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/docs/02-client-tools.md b/docs/02-client-tools.md index 0f28669..fab12ca 100644 --- a/docs/02-client-tools.md +++ b/docs/02-client-tools.md @@ -104,8 +104,9 @@ The following steps will enable shell tab completion on kubectl while using bash ``` echo "source <(kubectl completion bash)" >> ~/.bashrc && . ~/.bashrc ``` ->You can also omit the "&& bash" and reload the shell later. ->This will only enable tab completion for your current user. +> This will only enable tab completion for your current user. +> You can also run `echo "source <(kubectl completion bash)" >> /etc/profile.d/kubectl_completion.sh . /etc/profile` to get tab completion for all users. + ### Verification