Sort, use more stable formatting for commits by timezone

Switch to `git log` for formatting commits sorted by timezone, to avoid
odd formatting cases. Also sorts timezones from negative to positive.
This commit is contained in:
Cameron Rodriguez 2023-04-04 16:31:19 -04:00
parent 71d414eb4a
commit 6cdca7c7c7

View file

@ -874,9 +874,9 @@ function commitsByTimezone() {
fi
echo -e "Commits\tTimeZone"
git -c log.showSignature=false shortlog -n $_merges --format='%ad %s' \
git -c log.showSignature=false log $_merges --format='%ad %s' \
"${_author}" "$_since" "$_until" --date=iso $_log_options $_pathspec \
| cut -d " " -f 12 | grep -v -e '^[[:space:]]*$' | sort | uniq -c
| cut -d " " -f 3 | grep -v -e '^[[:space:]]*$' | sort -n | uniq -c
}
################################################################################