diff options
Diffstat (limited to 'completion/make.sh')
-rwxr-xr-x | completion/make.sh | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/completion/make.sh b/completion/make.sh new file mode 100755 index 0000000..dd00d05 --- /dev/null +++ b/completion/make.sh @@ -0,0 +1,12 @@ +#!/bin/bash + +pacman_bash_completion='/usr/share/bash-completion/completions/pacman' + +(IFS=; while read -r line; do + [ "${line:0:12}" = 'make_import ' ] && { + grep -Poz '(?<=\n)'"${line:12}"'\(\) \{\n(.*\n)*?\}' "$pacman_bash_completion" | + xargs -0 + } || { + echo "$line" + } +done) < 'bash.in' > 'bash' |