aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFurkan Sahin <furkan-dev@proton.me>2023-05-10 12:44:09 -0500
committerFurkan Sahin <furkan-dev@proton.me>2023-05-10 12:44:09 -0500
commit933b2eb2966864aef88c937fb3e6ce6da52facbe (patch)
tree1a7d990448fed6109a81d3ea790b516189c01415
parent4c4c76df12e8c851da16e08d460119de904383ec (diff)
Add instructions for completion
-rw-r--r--README.md12
1 files changed, 12 insertions, 0 deletions
diff --git a/README.md b/README.md
index 35096be..8fd1247 100644
--- a/README.md
+++ b/README.md
@@ -34,6 +34,18 @@ Then, source the `OPENAI_API_KEY` environmental variable in your shell's configu
source ~/.bashrc
```
+#### Bash / Zsh Completion
+
+`gpt-chat-cli` uses [argcomplete](https://github.com/kislyuk/argcomplete) to generate completion scripts for the `bash` or `zsh` shells.
+
+Currently, the recommended installation method is the explicit registeration of argcomplete with your shell by placing the following line in your `~/.bashrc` or `~/.zshrc`.
+
+```bash
+eval "$(register-python-argcomplete gpt-chat-cli)"
+```
+
+Argcomplete also supports registration through ["global completion"](https://github.com/kislyuk/argcomplete#global-completion). The aim of global completion is to automatically register any scripts which use argcomplete. This is not currently recommended as it seems to make some assumptions which do not hold for all users.
+
### User Guide
#### Basic Usage