mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-26 02:57:57 +00:00
9d5724f926
* CI: chore * CI: lsof and jq are installed * CI: generate docs with deps * CI: remove check width, fmt checks it * CI: simplify rules * CI: make CI image variable * CI: more chore * rm check_line_width.sh * CI: fix spellcheck; fix check-transaction * CI: return installing jq * lint: remove dupes
1003 B
1003 B
Shell completion
The Polkadot CLI command supports shell auto-completion. For this to work, you will need to run the completion script matching you build and system.
Assuming you built a release version using cargo build --release and use bash run the following:
source target/release/completion-scripts/polkadot.bash
You can find completion scripts for:
- bash
- fish
- zsh
- elvish
- powershell
To make this change persistent, you can proceed as follow:
First install
COMPL_DIR=$HOME/.completion
mkdir -p $COMPL_DIR
cp -f target/release/completion-scripts/polkadot.bash $COMPL_DIR/
echo "source $COMPL_DIR/polkadot.bash" >> $HOME/.bash_profile
source $HOME/.bash_profile
Update
When you build a new version of Polkadot, the following will ensure you auto-completion script matches the current binary:
COMPL_DIR=$HOME/.completion
mkdir -p $COMPL_DIR
cp -f target/release/completion-scripts/polkadot.bash $COMPL_DIR/
source $HOME/.bash_profile