Skip to content

Commit

Permalink
add git .mailmap file and use it
Browse files Browse the repository at this point in the history
  • Loading branch information
mvo5 committed Sep 20, 2018
1 parent 2506b9f commit c20f66c
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 6 deletions.
2 changes: 2 additions & 0 deletions .mailmap
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Sergio Cazzolato <sergiocazzolato@gmail.com> sergio-j-cazzolato <sergio.cazzolato@canonical.com>
John R. Lenton <jlenton@gmail.com> John Lenton <chipaca@users.noreply.github.com>
2 changes: 1 addition & 1 deletion cmd/snap/cmd_blame_generated.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ package main
// generated by mkauthors.sh; do not edit

func init() {
authors = []string{"Mark Shuttleworth", "Gustavo Niemeyer", "Sergio Schvezov", "Simon Fels", "Kyle Fazzari", "Sergio Cazzolato", "Leo Arias", "Gustavo Niemeyer", "Federico Gimenez", "Maciej Borzecki", "Jamie Strandboge", "Pawel Stolowski", "John R. Lenton", "Samuele Pedroni", "Zygmunt Krynicki", "Michael Vogt",}
authors = []string{"Mark Shuttleworth", "Gustavo Niemeyer", "Sergio Schvezov", "Simon Fels", "Kyle Fazzari", "Leo Arias", "Sergio Cazzolato", "Gustavo Niemeyer", "Federico Gimenez", "Maciej Borzecki", "Jamie Strandboge", "Pawel Stolowski", "John R. Lenton", "Samuele Pedroni", "Zygmunt Krynicki", "Michael Vogt"}
}
7 changes: 2 additions & 5 deletions mkauthors.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,13 +36,9 @@ if [ ! -d .git ]; then
exit
fi

# "John Lenton" and "John R. Lenton" are the same guy
raw_authors="$(git shortlog -s|sort -n|grep -v "John Lenton"|tail -n14|cut -f2)"
raw_authors="$(git shortlog -s|sort -n|tail -n14|cut -f2)"
authors=""
while read -r author; do
if [ "$author" = "sergio-j-cazzolato" ]; then
author="Sergio Cazzolato"
fi
authors="$authors \"$author\","
done <<< "$raw_authors"

Expand All @@ -57,3 +53,4 @@ func init() {
}
EOF

go fmt $GO_GENERATE_BUILDDIR/cmd/snap/cmd_blame_generated.go >/dev/null

0 comments on commit c20f66c

Please sign in to comment.