Skip to content

Commit 088c8b6

Browse files
authored
Merge pull request #40 from kyle-rader-msft/user/kyrader/repo-stats-patch-id-dedup
2 parents 9fa3f99 + b631fa3 commit 088c8b6

4 files changed

Lines changed: 444 additions & 97 deletions

File tree

Cargo.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "loki-cli"
3-
version = "2.4.0"
3+
version = "2.5.0"
44
authors = ["Kyle W. Rader"]
55
description = "Loki: 🚀 A Git productivity tool"
66
homepage = "https://github.com/kyle-rader/loki-cli"

README.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,19 @@ Analyze commits reachable from HEAD to see who has been landing work in a reposi
183183
- `--name` filters by author display name (repeatable, case-insensitive).
184184
- `--email` filters by author email (repeatable, case-insensitive).
185185
- `--all` includes all commits (default is first-parent only).
186+
- `--no-dedup` disables patch-id deduplication (see below).
187+
188+
#### Patch-id deduplication
189+
By default `repo stats` collapses commits that share the same `git patch-id` so that logically-identical changes are only counted once. This keeps contributor counts accurate when repository history contains rebased, cherry-picked, or migrated commits — for example when one repository's history was merged into another and the same patch now exists under two different SHAs.
190+
191+
For each patch-id group, the commit with the earliest author date is attributed to the original author. Commits with no patch (empty diffs, merge commits) are always counted individually.
192+
193+
When duplicates are collapsed, the summary line notes how many were removed:
194+
```
195+
Total commits: 4471 (838 duplicate patches collapsed; --no-dedup to disable)
196+
```
197+
198+
Pass `--no-dedup` to count every SHA individually (the pre-2.5.0 behavior).
186199

187200
#### Example
188201
```

0 commit comments

Comments
 (0)