From a2c6f430b5b484c8e1c103add25db2a98ab64c01 Mon Sep 17 00:00:00 2001
From: jxlwqq <jxlwqq@gmail.com>
Date: Thu, 30 Dec 2021 15:45:19 +0800
Subject: [PATCH] feat(dapr): add plugin for dapr

---
 plugins/dapr/README.md       | 9 +++++++++
 plugins/dapr/dapr.plugin.zsh | 4 ++++
 2 files changed, 13 insertions(+)
 create mode 100644 plugins/dapr/README.md
 create mode 100644 plugins/dapr/dapr.plugin.zsh

diff --git a/plugins/dapr/README.md b/plugins/dapr/README.md
new file mode 100644
index 000000000..e6c12bcef
--- /dev/null
+++ b/plugins/dapr/README.md
@@ -0,0 +1,9 @@
+# Dapr CLI
+
+The [Dapr CLI](https://docs.dapr.io/getting-started/install-dapr-cli/) is the main tool you’ll be using for various Dapr related tasks. You can use it to run an application with a Dapr sidecar, as well as review sidecar logs, list running services, and run the Dapr dashboard. The Dapr CLI works with both self-hosted and Kubernetes environments.
+
+To use it, add `dapr` to the plugins array of your zshrc file:
+
+```sh
+plugins=(... dapr)
+```
diff --git a/plugins/dapr/dapr.plugin.zsh b/plugins/dapr/dapr.plugin.zsh
new file mode 100644
index 000000000..dcfbda874
--- /dev/null
+++ b/plugins/dapr/dapr.plugin.zsh
@@ -0,0 +1,4 @@
+if [ $commands[dapr] ]; then
+  source <(dapr completion zsh)
+  compdef _dapr dapr
+fi