Replaced grep commit by grep with regex including git sha hash

myDailyStats() used grep commit to detect count of commits. This
also increases the count by mentioning commit in the commit
message.

Therefore a grep with regex is used that expects a 40 digit/char
SHA1 hash after the word commit.
This commit is contained in:
Pawaer
2021-04-24 21:46:34 +02:00
parent c6cb74a5e0
commit bf29c19cf5
+1 -1
View File
@@ -546,7 +546,7 @@ function myDailyStats() {
--author="$(git config user.name)" $_merges \
--since=$(date "+%Y-%m-%dT00:00:00") \
--until=$(date "+%Y-%m-%dT23:59:59") --reverse $_log_options \
| grep commit | wc -l) "commits"
| grep -E "commit [a-f0-9]{40}" | wc -l) "commits"
}
################################################################################