a150d8a7c0040de5a1b0246728dc3c2af3b4c423
- Author
- jxlwqq <jxlwqq@gmail.com>
- Committer
- GitHub <noreply@github.com>
- Date
Message
feat(istioctl): add plugin for istioctl (#10410)
* Add plugin for istioctl completion. close #10405
* fix typo
* Update README.md
Diff
1diff --git a/plugins/istioctl/README.md b/plugins/istioctl/README.md
2new file mode 100644
3index 0000000000000000000000000000000000000000..afd4d293c71d067705c1de5ebbd134ea84830553
4--- /dev/null
5+++ b/plugins/istioctl/README.md
6@@ -0,0 +1,9 @@
7+# Istioctl - Istio Command-line Tool
8+
9+The [istioctl](https://istio.io/latest/docs/ops/diagnostic-tools/istioctl/) tool is a configuration command line utility that allows service operators to debug and diagnose their Istio service mesh deployments.
10+
11+To use it, add `istioctl` to the plugins array of your zshrc file:
12+
13+```sh
14+plugins=(... istioctl)
15+```
16diff --git a/plugins/istioctl/istioctl.plugin.zsh b/plugins/istioctl/istioctl.plugin.zsh
17new file mode 100644
18index 0000000000000000000000000000000000000000..13ead1b2b51a60982c4fc9f9e370e83db88713bc
19--- /dev/null
20+++ b/plugins/istioctl/istioctl.plugin.zsh
21@@ -0,0 +1,4 @@
22+if [ $commands[istioctl] ]; then
23+ source <(istioctl completion zsh)
24+ compdef _istioctl istioctl
25+fi