Ignore zip comments in dump-package-stats
Use -q to silence zip comments, which also silences the first line. Bug: 67345114 Test: find vendor -name '*.apk' | xargs build/tools/dump-package-stats Change-Id: Icb319c603de7c29644c58520213940179f67b7e4
This commit is contained in:
committed by
Tim Joines
parent
90e737c6b6
commit
905b2e00f1
@@ -77,7 +77,7 @@ do
|
|||||||
then
|
then
|
||||||
fail "$file doesn't exist or isn't a file"
|
fail "$file doesn't exist or isn't a file"
|
||||||
fi
|
fi
|
||||||
unzip -lv "$file" | awk '
|
unzip -lvq "$file" | awk '
|
||||||
BEGIN {
|
BEGIN {
|
||||||
total_compressed = 0;
|
total_compressed = 0;
|
||||||
total_uncompressed = 0;
|
total_uncompressed = 0;
|
||||||
@@ -88,16 +88,6 @@ do
|
|||||||
# Make sure the output of unzip -lv looks like something we expect.
|
# Make sure the output of unzip -lv looks like something we expect.
|
||||||
#
|
#
|
||||||
NR == "1" {
|
NR == "1" {
|
||||||
if ($1 != "Archive:") {
|
|
||||||
print "'$PROGNAME': ERROR: Unexpected zip listing format" > \
|
|
||||||
"/dev/stderr";
|
|
||||||
print "'$PROGNAME': ERROR: Line 1 is \"" $0 "\"" > \
|
|
||||||
"/dev/stderr";
|
|
||||||
failed = 1;
|
|
||||||
exit 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
NR == "2" {
|
|
||||||
if (NF != "8" ||
|
if (NF != "8" ||
|
||||||
$1 != "Length" ||
|
$1 != "Length" ||
|
||||||
$2 != "Method" ||
|
$2 != "Method" ||
|
||||||
|
Reference in New Issue
Block a user