aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/git-stats-graph.py
diff options
context:
space:
mode:
authorBence Ferdinandy <bence@ferdinandy.com>2024-01-19 14:57:17 +0100
committerRobin Jarry <robin@jarry.cc>2024-01-19 23:31:33 +0100
commit978b5e444215255a9671ce439f1594888697f799 (patch)
treed3ef1c6139ed519697b27ba0dc98914452ebbc38 /contrib/git-stats-graph.py
parent9a255ab5b7bc8c85b990cf9a290fc3a1ff3b7ce4 (diff)
downloadaerc-978b5e444215255a9671ce439f1594888697f799.tar.gz
git-stats-graph: fix release dates
The dates associated with tags and HEAD was always the previous tag. Fix the indexing for date parsing. Signed-off-by: Bence Ferdinandy <bence@ferdinandy.com> Acked-by: Robin Jarry <robin@jarry.cc>
Diffstat (limited to 'contrib/git-stats-graph.py')
-rwxr-xr-xcontrib/git-stats-graph.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/contrib/git-stats-graph.py b/contrib/git-stats-graph.py
index 7632d566..dc944c18 100755
--- a/contrib/git-stats-graph.py
+++ b/contrib/git-stats-graph.py
@@ -44,7 +44,9 @@ def stats():
for i, t in enumerate(tags[:-1]):
counts.append(int(git("rev-list", f"{t}..{tags[i+1]}", "--count")))
dates.append(
- date.fromisoformat(git("show", "-s", "--format=%cs", t).split("\n")[-1])
+ date.fromisoformat(
+ git("show", "-s", "--format=%cs", tags[i + 1]).split("\n")[-1]
+ )
)
statline = git("diff", "--stat", t, tags[i + 1]).split("\n")[-1]
fnum, _, _, ins, _, dels, _ = statline.split()