summaryrefslogtreecommitdiffstats
path: root/bash-completion
diff options
context:
space:
mode:
authorMatthew Monaco <matthew.monaco@0x01b.net>2012-03-16 03:59:11 +0100
committerDave Reisner <dreisner@archlinux.org>2012-03-16 04:49:34 +0100
commitc1a07b155430357052e43c52edaaa89d002aaa7e (patch)
treea93ba7d04ec60c352061535bd432dd645b094020 /bash-completion
parent19c69a16a84c945c26e1ad83123c2df27ce3d190 (diff)
downloadmkinitcpio-c1a07b155430357052e43c52edaaa89d002aaa7e.tar.gz
mkinitcpio-c1a07b155430357052e43c52edaaa89d002aaa7e.tar.xz
bash-completion: find hooks in /usr/lib
[dreisner: add handling for -A flag] Signed-off-by: Dave Reisner <dreisner@archlinux.org>
Diffstat (limited to 'bash-completion')
-rw-r--r--bash-completion5
1 files changed, 3 insertions, 2 deletions
diff --git a/bash-completion b/bash-completion
index ee544ec..6329702 100644
--- a/bash-completion
+++ b/bash-completion
@@ -33,7 +33,7 @@ _find_kernel_versions() {
_mkinitcpio() {
local action cur prev
- action="-b -c -g -H -h -k -L -M -n -p -S -s -v -z"
+ action="-A -b -c -g -H -h -k -L -M -n -p -S -s -v -z"
_get_comp_words_by_ref cur prev
case "$prev" in
-c|-g) _filedir;;
@@ -41,7 +41,8 @@ _mkinitcpio() {
-b) _filedir -d;;
-p) COMPREPLY=($(cd /etc/mkinitcpio.d/ && compgen -X '!*.preset' -f -- $cur))
COMPREPLY=("${COMPREPLY[@]%.preset}");;
- -H|-S) COMPREPLY=($(cd /lib/initcpio/install/ && compgen -f -- $cur));;
+ -A|-H|-S) COMPREPLY=($(cd /lib/initcpio/install/ && compgen -f -- $cur) \
+ $(cd /usr/lib/initcpio/install/ && compgen -f -- $cur));;
*) COMPREPLY=($(compgen -W "${action}" -- "$cur"));;
esac
}