]> git.cworth.org Git - notmuch/blob - devel/author-scan.sh
lib/message-property: sync removed properties to the database
[notmuch] / devel / author-scan.sh
1 #!/bin/sh
2
3 FILE_EXCLUDE='corpora'
4 AUTHOR_EXCLUDE='uncrustify'
5 # based on the FSF guideline, for want of a better idea.
6 THRESHOLD=15
7
8 git ls-files | grep -v -e "$FILE_EXCLUDE" | tr '\n' '\0' | xargs -0 -n 1 \
9                                                   git blame -w --line-porcelain -- | \
10     sed -n "/$AUTHOR_EXCLUDE/d; s/^[aA][uU][tT][hH][Oo][rR] //p" | \
11     sort -fd | uniq -ic | awk "\$1 >= $THRESHOLD" | sort -nr