Skip to content

Commit 0053642

Browse files
committed
define within
1 parent cd283c7 commit 0053642

File tree

2 files changed

+10
-10
lines changed

2 files changed

+10
-10
lines changed

src/bkg.sh

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,16 @@ main() {
140140
sort "$connections" | uniq -c | sort -nr | awk '{print $2}' >"$connections".bak
141141
mv "$connections".bak "$connections"
142142

143+
missed_owners() {
144+
pushd "$BKG_INDEX_DIR" >/dev/null 2>&1 || echo ""
145+
cutoff=$(get_BKG BKG_BATCH_FIRST_STARTED)
146+
git ls-tree -r --name-only "$BKG_INDEX" ./ \
147+
| xargs -r -I filename git log -1 --format='%cs filename' filename \
148+
| awk -v cutoff="$cutoff" 'cutoff != "" && $1 < cutoff {print}' \
149+
| sort | grep -oP '(?<= )[^/]+(?=/)' | uniq | awk '{print "0/"$1}'
150+
popd >/dev/null 2>&1 || echo ""
151+
}
152+
143153
echo "$(
144154
missed_owners
145155
cat "$BKG_OWNERS"

src/lib/util.sh

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -661,14 +661,4 @@ clean_owners() {
661661
awk '!seen[$0]++' "$1" >"$temp_file" && cp -f "$temp_file" "$1"
662662
}
663663

664-
missed_owners() {
665-
pushd "$BKG_INDEX_DIR" >/dev/null 2>&1 || echo ""
666-
cutoff=$(get_BKG BKG_BATCH_FIRST_STARTED)
667-
git ls-tree -r --name-only "$BKG_INDEX" ./ \
668-
| xargs -r -I filename git log -1 --format='%cs filename' filename \
669-
| awk -v cutoff="$cutoff" 'cutoff != "" && $1 < cutoff {print}' \
670-
| sort | grep -oP '(?<= )[^/]+(?=/)' | uniq | awk '{print "0/"$1}'
671-
popd >/dev/null 2>&1 || echo ""
672-
}
673-
674664
set +o allexport

0 commit comments

Comments
 (0)