Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs(cli): add completions commands #4819

Merged
merged 15 commits into from
Jan 24, 2025
65 changes: 64 additions & 1 deletion docs/content/references/cli.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -36,5 +36,68 @@ The six most useful commands to users are the following:
- **[IOTA Validator CLI](./cli/validator.mdx):** Use the `iota validator` command to access tools useful for IOTA validators.
- **[IOTA Genesis Ceremony CLI](./cli/ceremony.mdx):** Use the `iota ceremony` command to build a genesis blob.


Use the `help` flag for the commands that are not documented yet. For example, `iota validator --help`.

## IOTA CLI Completion

<Tabs groupId="shell">

<TabItem label="Bash" value="bash">

```sh
iota generate-completions --shell bash > ~/.iota/completion.bash
echo "source ~/.iota/completion.bash" >> ~/.bashrc
```

</TabItem>

<TabItem label="Elvish" value="elvish">

TODO

```sh
iota generate-completions --shell elvish
```

</TabItem>

<TabItem label="Fish" value="fish">

```sh
iota generate-completions --shell fish > iota.fish
mv iota.fish ~/.config/fish/completions
```

</TabItem>

<TabItem label="Nushell" value="nushell">

TODO

```sh
iota generate-completions --shell nushell
```

</TabItem>

<TabItem label="Powershell" value="powershell">

TODO

```sh
iota generate-completions --shell powershell
```

</TabItem>

<TabItem label="Zsh" value="zsh">

```sh
iota generate-completions --shell zsh > _iota
sudo mv _iota /usr/share/zsh/functions/Completion/Zsh/
thibault-martinez marked this conversation as resolved.
Show resolved Hide resolved
source ~/.zshrc
```

</TabItem>

</Tabs>
Loading