Skip to content

Set up optional development features


Tab completion

Completion is achieved by saving a script and then executing it as a part of your shell's startup sequence.

Afterward, you'll need to start a new shell in order for the changes to take effect.

Save the script somewhere:

_DDA_COMPLETE=zsh_source dda > ~/.dda-complete.zsh

Source the file in ~/.zshrc:

. ~/.dda-complete.zsh

Save the script somewhere:

_DDA_COMPLETE=bash_source dda > ~/.dda-complete.bash

Source the file in ~/.bashrc (or ~/.bash_profile if on macOS):

. ~/.dda-complete.bash

Save the script in ~/.config/fish/completions:

_DDA_COMPLETE=fish_source dda > ~/.config/fish/completions/dda.fish

Tip

There is also limited tab completion support for the legacy invoke tasks. Here's an example:

echo "source <(dda inv --print-completion-script zsh)" >> ~/.zshrc

Pre-commit hooks

The CI runs a number of required checks using pre-commit and running those locally can speed up the development process.

  1. Install pre-commit by running the following command.

    dda self pip install pre-commit
    
  2. Use dda to configure the pre-commit hooks.

    dda inv setup.pre-commit