1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-07-07 14:21:48 +02:00

nix: Implement basic bash completion

This commit is contained in:
Eelco Dolstra 2020-05-10 20:32:21 +02:00
parent 14a3a62bfc
commit 91ddee6bf0
9 changed files with 95 additions and 4 deletions

7
misc/bash/completion.sh Normal file
View file

@ -0,0 +1,7 @@
function _complete_nix {
while IFS= read -r line; do
COMPREPLY+=("$line")
done < <(NIX_GET_COMPLETIONS=$COMP_CWORD "${COMP_WORDS[@]}")
}
complete -F _complete_nix nix