1
0
Derivar 0

Add basic bash-completion wrt #109

Este cometimento está contido em:
Julian Ospald 2019-07-24 16:53:15 +08:00
ascendente 1b719ead22
cometimento 580da22569
Não foi encontrada uma chave conhecida para esta assinatura, na base de dados
ID da chave GPG: 511B62C09D50CD28
2 ficheiros modificados com 23 adições e 0 eliminações

11
.bash-completion Ficheiro normal
Ver ficheiro

@ -0,0 +1,11 @@
_ghcup()
{
local cur
COMPREPLY=()
cur="${COMP_WORDS[COMP_CWORD]}"
if [[ ${#COMP_WORDS[*]} -le 2 ]]; then
COMPREPLY=($(compgen -W "$(ghcup --list-commands)" -- $cur))
fi
return 0
} &&
complete -F _ghcup ghcup

12
ghcup
Ver ficheiro

@ -2049,6 +2049,18 @@ while [ $# -gt 0 ] ; do
-V|--version)
printf "%s\\n" "${VERSION}"
exit 0;;
--list-commands)
echo "changelog
compile
debug-info
install
install-cabal
list
print-system-reqs
rm
set
upgrade"
exit 0;;
-h|--help)
usage;;
-w|--wget)