first commit

This commit is contained in:
2026-03-07 12:28:30 +01:00
commit bdc61ca4fe
21 changed files with 2403 additions and 0 deletions

27
awk/collect_dir_info.awk Normal file
View File

@@ -0,0 +1,27 @@
BEGIN {
slen = length(src)
}
{
if (length($0) <= slen) {
next
}
rel = substr($0, slen + 2)
parent = rel
if (sub(/\/[^\/]+$/, "", parent) == 0) {
parent = "."
}
all[parent]++
if (is_dir[rel]) {
dirs[parent]++
}
is_dir[parent] = 1
}
END {
for (parent in all) {
printf "%s|%d|%d\n", parent, all[parent], dirs[parent]
}
}