From 5338e739163ecad2dc877c21c36488f88710ff29 Mon Sep 17 00:00:00 2001 From: Neo Liang Date: Wed, 22 Jul 2020 09:58:47 +0800 Subject: [PATCH] add documentation for how to enable source completion in zsh --- README.md | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/README.md b/README.md index da64c6cdc..3c9fea928 100644 --- a/README.md +++ b/README.md @@ -70,11 +70,20 @@ sudo mv bin/darwin-amd64/gardenctl-darwin-amd64 /usr/local/bin/gardenctl `gardenctl` supports auto completion. This recommended feature is bound to `gardenctl` or the alias `g`. To configure it you can run: +if you are using `bash`: + ```bash echo "source <(gardenctl completion bash)" >> ~/.bashrc source ~/.bashrc ``` +if you are using `zsh`: + +```bash +echo "source <(gardenctl completion zsh)" >> ~/.zshrc +source ~/.zshrc +``` + ### Via Dockerfile First clone the repository as described in the the build step "From source". As next step add the garden "config" file and "clusters" folder with the corresponding kubeconfig files for the garden cluster. Then build the container image via `docker build -t gardener/gardenctl:v1 .` in the cloned repository and run a shell in the image with `docker run -it gardener/gardenctl:v1 /bin/bash`.