Skip to content

Commit bf95d3f

Browse files
authored
Merge pull request #34325 from mtovmassian/fix-zh-bash-alias-auto-completion
[zh] Update Bash alias auto-completion
2 parents c61be7d + 63938e4 commit bf95d3f

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

content/zh-cn/docs/reference/kubectl/cheatsheet.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ echo "source <(kubectl completion bash)" >> ~/.bashrc # 在您的 bash shell 中
5656

5757
```bash
5858
alias k=kubectl
59-
complete -F __start_kubectl k
59+
complete -o default -F __start_kubectl k
6060
```
6161

6262
### ZSH

content/zh-cn/docs/tasks/tools/included/optional-kubectl-configs-bash-linux.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ If you have an alias for kubectl, you can extend shell completion to work with t
8686

8787
```bash
8888
echo 'alias k=kubectl' >>~/.bashrc
89-
echo 'complete -F __start_kubectl k' >>~/.bashrc
89+
echo 'complete -o default -F __start_kubectl k' >>~/.bashrc
9090
```
9191

9292
{{< note >}}

content/zh-cn/docs/tasks/tools/included/optional-kubectl-configs-bash-mac.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ You now have to ensure that the kubectl completion script gets sourced in all yo
148148

149149
```bash
150150
echo 'alias k=kubectl' >>~/.bash_profile
151-
echo 'complete -F __start_kubectl k' >>~/.bash_profile
151+
echo 'complete -o default -F __start_kubectl k' >>~/.bash_profile
152152
```
153153

154154
<!--

0 commit comments

Comments
 (0)