Rollup merge of #29843 - arcnmx:authors, r=brson

Duplicate entries removed. This doesn't quite completely allow for generating AUTHORS.txt from scratch but it's much closer now.
This commit is contained in:
Steve Klabnik 2015-11-16 16:22:48 -05:00
commit 3252aeb22d
3 changed files with 104 additions and 43 deletions

4
src/etc/add-authors.sh Normal file → Executable file
View file

@ -30,8 +30,8 @@ range="$1"
authors_file="./AUTHORS.txt"
tmp_file="./AUTHORS.txt.tmp"
old_authors="$(cat "$authors_file" | tail -n +2 | sed "/^$/d" | sort)"
new_authors="$(git log "$range" --format="%aN <%aE>" | sort | uniq)"
new_authors="$(git log "$range" --use-mailmap --format="%aN <%aE>" | sort | uniq)"
printf "%s\n\n" "Rust was written by these fine people:" > "$tmp_file"
printf "%s\n%s" "$old_authors" "$new_authors" | sort | uniq >> "$tmp_file"
printf "%s\n%s" "$old_authors" "$new_authors" | sort -fs | uniq >> "$tmp_file"
mv -f "$tmp_file" "$authors_file"