From cf02dbdd65d76e0fcf6c367c0bf93b60ce3b3075 Mon Sep 17 00:00:00 2001 From: Daniel Mueller Date: Fri, 9 Apr 2021 21:04:49 -0700 Subject: [PATCH] Make shell completion instructions more generic for other shells For a while now we have supported the generation of argument completion scripts for various shells. Yet, the README was only talking about the usage of bash. This change updates the document to at least mention the possibility of creation of such completion scripts for other shells. --- README.md | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index f68a4498..c7b36839 100644 --- a/README.md +++ b/README.md @@ -113,9 +113,9 @@ It is recommended that the resulting executable be installed in a directory accessible via the `PATH` environment variable. -#### Bash Completion -**nitrocli** comes with Bash completion support for options and -arguments to them. A completion script can be generated via the +#### Shell Completion +**nitrocli** comes with completion support for options and arguments to +them (for various shells). A completion script can be generated via the `shell-complete` utility program and then only needs to be sourced to make the current shell provide context-sensitive tab completion support. ```bash @@ -123,8 +123,13 @@ $ cargo run --bin=shell-complete bash > nitrocli.bash $ source nitrocli.bash ``` -The generated completion script can be installed system-wide as usual -and sourced through Bash initialization files, such as `~/.bashrc`. +The generated completion script (`bash` specific, in this case) can be +installed system-wide as usual and sourced through Bash initialization +files, such as `~/.bashrc`. + +Completion scripts for other shells work in a similar manner. Please +refer to the help text (`--help`) of the `shell-complete` program for +the list of supported shells. Known Problems