> ## Documentation Index
> Fetch the complete documentation index at: https://supaschema.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# completion

> Print a shell completion script for supaschema commands.

Use `completion` when you want shell autocomplete for supaschema commands.

The command prints a completion script for bash, zsh, or fish.

## Run it

```bash theme={null}
npx supaschema completion bash >> ~/.bashrc
npx supaschema completion zsh >> ~/.zshrc
npx supaschema completion fish > ~/.config/fish/completions/supaschema.fish
```

Reload the shell after installing the script.

## Arguments

<ParamField path="<shell>" type="bash | zsh | fish">
  Required shell name.
</ParamField>

## Exit codes

| Code | Meaning                              |
| ---- | ------------------------------------ |
| `0`  | Completion script printed            |
| `1`  | Unsupported shell or runtime failure |

## Related

<CardGroup cols={2}>
  <Card title="Commands" icon="terminal" href="/docs/commands">
    Pick the command you want to run.
  </Card>

  <Card title="Installation" icon="download" href="/docs/installation">
    Add supaschema before installing completions.
  </Card>
</CardGroup>
