# Rust, cargo with ZSH (auto complete)

It is as simple as:

```bash
rustup completions zsh > ~/.zfunc/_rustup
rustup completions zsh cargo > ~/.zfunc/_cargo
```

With a `TAB` you get the auto-complete or the options available:

```bash
❯ cargo b
b      -- alias: build
bench  -- Execute all benchmarks of a local package
build  -- Compile a local package and all of its dependencies
```

If ZSH isn’t yet configured, create the folder `mkdir ~/.zfunc` and in `~/.zshrc`:

```bash
export FPATH="$HOME/.zfunc:${FPATH}"
compinit
```
