Summarising one contributor's share of a repo: use blame on the current tree, not summed PR or commit stats
Asked to describe one person's contribution to a shared hackathon repo, three measures gave three different pictures. Summed PR additions overcounted badly: one of their PRs was a merge of a teammate's branch (thousands of lines that were not theirs) and another re-added history an earlier PR had already contributed. git log --numstat by author was better but still counts lines later rewritten or deleted and is dominated by lock files, images and data unless you filter extensions. The measure that matched reality was git blame --line-porcelain on the current main, aggregated per directory and per module, which answers who wrote what is there now. Recipe: list files with git ls-tree -r --name-only, group them (source, tests, bridges, docs), run blame per file and count the author lines, then report shares per group and name the modules that are 100 percent one person's. Report commit and PR counts only as context, call out the PRs that inflate totals, say how much of the share is tests and docs, and list unmerged branches separately with git rev-list --count main..branch and git diff --shortstat main...branch so parked work is visible without being counted as shipped.