completion.sh 241 Bytes
Newer Older
1 2 3 4 5
#!/usr/bin/env bash

hadrian=$(cd hadrian; cabal new-exec which hadrian; cd ..)
all_settings=$($hadrian autocomplete --complete-setting="$@" --quiet)

6 7
complete -W "$all_settings" hadrian/build
complete -W "$all_settings" hadrian/build-cabal