tests: simplify sbin check.
This commit is contained in:
parent
e7f25571d0
commit
0e4cc45a5b
1 changed files with 3 additions and 5 deletions
|
|
@ -353,12 +353,10 @@ check_sbin() {
|
||||||
for file in "${files[@]}"; do
|
for file in "${files[@]}"; do
|
||||||
(
|
(
|
||||||
while read -r match; do
|
while read -r match; do
|
||||||
if [[ $match =~ (@\{sbin\}/($pattern)) ]]; then
|
name="${match/\@\{sbin\}\//}"
|
||||||
name="${BASH_REMATCH[2]}"
|
|
||||||
if ! _in_array "$name" "${sbin[@]}"; then
|
if ! _in_array "$name" "${sbin[@]}"; then
|
||||||
_err compatibility "$file" "contains '@{sbin}/$name' but it is not in sbin.list"
|
_err compatibility "$file" "contains '@{sbin}/$name' but it is not in sbin.list"
|
||||||
fi
|
fi
|
||||||
fi
|
|
||||||
done < <(grep --only-matching -E "@\{sbin\}/$pattern" "${file%%:*}")
|
done < <(grep --only-matching -E "@\{sbin\}/$pattern" "${file%%:*}")
|
||||||
) &
|
) &
|
||||||
_wait jobs
|
_wait jobs
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue