aboutsummaryrefslogtreecommitdiff
path: root/release
diff options
context:
space:
mode:
Diffstat (limited to 'release')
-rw-r--r--release/scripts/mtree-to-plist.awk22
1 files changed, 9 insertions, 13 deletions
diff --git a/release/scripts/mtree-to-plist.awk b/release/scripts/mtree-to-plist.awk
index 12a6bd97fd02..453c63bb54f0 100644
--- a/release/scripts/mtree-to-plist.awk
+++ b/release/scripts/mtree-to-plist.awk
@@ -1,35 +1,31 @@
#!/usr/bin/awk
/^[^#]/ {
gsub(/^\./,"", $1)
- uname=""
- gname=""
- mode=""
- flags=""
- tags=""
+ uname = gname = mode = flags = tags = ""
for (i=2; i<=NF; i++) {
if ($i ~ /^uname=/) {
uname=$i
- gsub(/uname=/, "", uname);
+ gsub(/uname=/, "", uname)
} else if ($i ~ /^gname=/) {
gname=$i
- gsub(/gname=/, "", gname);
+ gsub(/gname=/, "", gname)
} else if ($i ~ /^mode=/) {
mode=$i
- gsub(/mode=/,"", mode);
+ gsub(/mode=/,"", mode)
} else if ($i ~ /^flags=/) {
flags=$i
- gsub(/flags=/, "", flags);
+ gsub(/flags=/, "", flags)
} else if ($i ~ /^tags=/) {
tags=$i
- gsub(/tags=/, "", tags);
+ gsub(/tags=/, "", tags)
}
}
if (length(tags) == 0)
next
if (tags ~ /package=/) {
- gsub(/package=/,"",tags);
- gsub(/,/, "-", tags);
- gsub(/runtime-/, "", tags);
+ gsub(/package=/,"",tags)
+ gsub(/,/, "-", tags)
+ gsub(/runtime-/, "", tags)
pkg=tags
} else {
pkg=tags