Skip to content

Instantly share code, notes, and snippets.

@jesselawson
Created February 17, 2022 04:46
Show Gist options
  • Save jesselawson/0490e1b7ef87b9aeb672caa3c974cb36 to your computer and use it in GitHub Desktop.
Save jesselawson/0490e1b7ef87b9aeb672caa3c974cb36 to your computer and use it in GitHub Desktop.
A useful shell script for emitting your contributions to whichever repo you're currently in
#!/usr/bin/env bash
git log --pretty=format:'' --numstat "$@" | awk 'NF' | awk '{insertions+=$1; deletions+=$2} END {print NR, "files changed,", insertions, "insertions(+),", deletions, "deletions(+)"}';
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment