Use tee to write to /etc/bash_completion.d/kubectl

This commit is contained in:
Carlos Domingues 2021-11-29 00:43:34 -03:00 committed by GitHub
parent 2c6a411fde
commit cde216e2f4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -37,7 +37,7 @@ You now need to ensure that the kubectl completion script gets sourced in all yo
- Add the completion script to the `/etc/bash_completion.d` directory:
```bash
kubectl completion bash >/etc/bash_completion.d/kubectl
echo -e "$(kubectl completion bash)" | sudo tee /etc/bash_completion.d/kubectl > /dev/null
```
If you have an alias for kubectl, you can extend shell completion to work with that alias: