Fixed some issues with mkdevbranch; giving better normalization of the input to uniq, and correctly using the alias list to provide the correct alias for email addresses where localpart should not be used to derive the svn branch name.

- Legacy-Id: 12312
This commit is contained in:
Henrik Levkowetz 2016-11-08 19:19:45 +00:00
parent f68d0c6f6b
commit a1bdbaf81e

View file

@ -150,16 +150,17 @@ else
import sys, re
afile = open("aliases")
aliases = dict([ line.strip().split(None,1) for line in afile.read().splitlines() ])
for line in sys.stdin:
blank, name, email, rest = line.strip().split("||", 3)
login, dummy = re.split("[@.]", email, 1)
if login in aliases:
login = aliases[login]
if email in aliases:
login = aliases[email]
print "\t".join((login.strip().lower(), email.strip().lower(), name.strip())) ' \
| update $progdir/sprint$n.txt
done
cat $(ls $progdir/sprint*.txt | tail -n 2) $progdir/extras.txt | sed 's/[ \t]*$//' | sort | uniq | while read login email name; do
cat $(ls $progdir/sprint*.txt | tail -n 2) $progdir/extras.txt | sed -r -e 's/[ \t]*$//' -e 's/[ \t]+/ /g' | sort | uniq | while read login email name; do
echo ""
echo "$login ($name <$email>):"
mksvndir $login