1 |
commit: ed4fa2c54dffce108bfd0e2d485e4c83c32d6462 |
2 |
Author: Ulrich Müller <ulm <AT> gentoo <DOT> org> |
3 |
AuthorDate: Fri Feb 3 22:47:23 2012 +0000 |
4 |
Commit: Ulrich Mueller <ulm <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Feb 3 22:51:19 2012 +0000 |
6 |
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/qa-scripts.git;a=commit;h=ed4fa2c5 |
7 |
|
8 |
check_eclasses_eapis.sh: Fix awk syntax. |
9 |
|
10 |
This avoids false positives for eclasses whose name is a substring |
11 |
of another eclass's name. (Same for EAPIs.) |
12 |
|
13 |
--- |
14 |
check_eclasses_eapis.sh | 4 ++-- |
15 |
1 files changed, 2 insertions(+), 2 deletions(-) |
16 |
|
17 |
diff --git a/check_eclasses_eapis.sh b/check_eclasses_eapis.sh |
18 |
index 380b131..a5eb736 100755 |
19 |
--- a/check_eclasses_eapis.sh |
20 |
+++ b/check_eclasses_eapis.sh |
21 |
@@ -25,11 +25,11 @@ for x in ${ECLASSES}; do |
22 |
echo "Processing eclass \"${x}\"" |
23 |
rm -rf "${x}" |
24 |
mkdir "${x}" |
25 |
- awk -F'=' '$3 ~ /'"${x%.eclass}"'[ "]/ {print $1" "$2}' "${TMPEAPIS}" > "${TMPECLASS}" |
26 |
+ awk -F'=' '$3 ~ /[ "]'"${x%.eclass}"'[ "]/ {print $1" "$2}' "${TMPEAPIS}" > "${TMPECLASS}" |
27 |
pushd "${x}" > /dev/null |
28 |
echo "Overall statistic for eclass \"${x}\":" > "STATS.txt" |
29 |
for y in ${KNOWN_EAPIS}; do |
30 |
- awk -F ' ' '$3 ~ /'"${y}"'/ {print $1}' "${TMPECLASS}" > "${y}.txt" |
31 |
+ awk -F ' ' '$3 ~ /"'"${y}"'"/ {print $1}' "${TMPECLASS}" > "${y}.txt" |
32 |
tmpval=$(wc -l "${y}.txt" |cut -d' ' -f1) |
33 |
echo "EAPI=${y} count: ${tmpval}" >> "STATS.txt" |
34 |
done |