From: Chris Koeritz Date: Thu, 22 Jul 2021 13:44:39 +0000 (-0400) Subject: removing snapshots from counts. X-Git-Tag: 2.140.134~12^2~18 X-Git-Url: https://feistymeow.org/gitweb/?a=commitdiff_plain;h=9ec7173ae1ad1f26e96846669a98a1bf4db8f287;p=feisty_meow.git removing snapshots from counts. --- diff --git a/scripts/files/fast_counter.sh b/scripts/files/fast_counter.sh index 6ab48990..c85723e9 100644 --- a/scripts/files/fast_counter.sh +++ b/scripts/files/fast_counter.sh @@ -2,14 +2,15 @@ for dir in "${@}"; do echo -n "files in '$dir':" - /bin/ls -1fR "$dir" | grep -v "^$" | grep -v "^\.$" | grep -v "^\.\.$" | grep -v ".*:$" | wc -l + /bin/ls -1fR "$dir" | grep -v "^$" | grep -v "^\.$" | grep -v "^\.\.$" | grep -v ".*:$" | grep -v "\.snapshot" | wc -l # patterns that remove files from being counted, above: # - # ^$ -- all blank lines - # ^\.$ -- all lines with just a dot (current directory) - # ^\.\.$ -- all lines with just two dots (parent directory) - # .*:$ -- all lines that end with a colon (directory heading from recursive ls) + # ^$ -- all blank lines + # ^\.$ -- all lines with just a dot (current directory) + # ^\.\.$ -- all lines with just two dots (parent directory) + # .*:$ -- all lines that end with a colon (directory heading from recursive ls) + # \.snapshot -- all lines mentioning the snapshot directory. done