From 0d00842ffe06d7dd99563da67d8809d75b7117c5 Mon Sep 17 00:00:00 2001 From: Henrik Levkowetz Date: Thu, 12 Jun 2014 10:07:34 +0000 Subject: [PATCH] Updated version of mkdevbranch. - Legacy-Id: 7890 --- bin/mkdevbranch | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) diff --git a/bin/mkdevbranch b/bin/mkdevbranch index f6fe26201..102448b3f 100755 --- a/bin/mkdevbranch +++ b/bin/mkdevbranch @@ -1,6 +1,6 @@ #!/bin/bash -version=0.22 +version=0.23 program=${0##*/} progdir=${0%/*} if [ "$progdir" = "$program" ]; then progdir="."; fi @@ -28,6 +28,7 @@ function version() { #[ $1 -gt 70 ] || die "Expected the ietf number as argument on the command line, but found '$1'" #if [ "$1" ]; then arg=$1; else arg=$(svn info http://svn.tools.ietf.org/svn/tools/ietfdb/trunk/ | egrep "^Last Changed Rev" | awk '{print $4}'); fi + if [ "$1" ]; then arg=$1; else arg=$(svn ls http://svn.tools.ietf.org/svn/tools/ietfdb/tags/ | grep '^[1-9]' | tail -n 1 | sed -r 's/^(.*)\/$/v\1/' ); fi if [ "${arg:0:1}" = "v" ]; then @@ -51,24 +52,25 @@ function mksvndir() { fi } +cd $progdir + num=$( < /www/tools.ietf.org/meta/current-ietf-number.txt) -for n in $(seq $((num-5)) $num); do +for n in $(seq $((num-3)) $num); do trac-admin /www/tools.ietf.org/tools/ietfdb wiki export IETF${n}SprintSignUp \ | egrep "^\|\|" | tail -n +2 | python -c ' import sys, re -altlogin = { - "ietf@augustcellars.com": "schaad", -} +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 email in altlogin: - login = altlogin[email] + if login in aliases: + login = aliases[login] 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) | sed 's/[ \t]*$//' | sort | uniq | while read login email name; do +cat $(ls $progdir/sprint*.txt | tail -n 2) $progdir/extras.txt | sed 's/[ \t]*$//' | sort | uniq | while read login email name; do echo "" echo "$login ($name <$email>):" mksvndir $login @@ -85,8 +87,10 @@ cat $(ls $progdir/sprint*.txt | tail -n 2) | sed 's/[ \t]*$//' | sort | uniq | w ${rev:+This branch is based on $rev. }You can check it out by doing svn co http://svn.tools.ietf.org/svn/tools/ietfdb/personal/$login/$target - (More instructions about setup is available at - http://trac.tools.ietf.org/tools/ietfdb/wiki/SprintCoderSetup) + Please read the instructions about sprint coder setup at + http://trac.tools.ietf.org/tools/ietfdb/wiki/SprintCoderSetup + -- both the workflow description and the details of setting up your + environment. Best regards,