Skip to content

completion

Output a shell tab-completion script for nschema.

Terminal window
nschema completion <shell>

Supported shells: bash, zsh, fish, pwsh.

The quickest way to enable completion permanently is completion install, which wires it into your shell’s startup file for you:

Terminal window
nschema completion install bash

Remove it again with completion uninstall:

Terminal window
nschema completion uninstall bash

Prefer to manage it yourself? Source the script in your current shell, or write it to your shell’s completion directory:

Terminal window
# current shell
source <(nschema completion bash)
# install permanently
nschema completion bash > /etc/bash_completion.d/nschema

Completion covers commands, options, and their fixed value sets (for example the --destructive-actions error|warn|allow choices). It also completes dynamic values that depend on your project: --environment <TAB> offers the environment names found in the project’s *.env.<name>.sql overlays, resolved against any --directory already on the line.

Nothing. It writes a completion script to stdout.