| OLD | NEW |
| 1 #!/bin/bash | 1 #!/bin/bash |
| 2 | 2 |
| 3 LAST_TAG=`git tag | grep ^v | tail -n1` | 3 LAST_TAG=`git tag | grep ^v | tail -n1` |
| 4 | 4 |
| 5 # Determine the lastest two versions sorting the semvers correctly. | 5 git log v0.9.3..HEAD | grep Author | sort | uniq | sed 's/Author: \(.*\) \<.*/\1
/' | tr "\\n" ", " | sed 's/,$/\n/' | sed 's/\,/, /g' |
| 6 REV_RANGE=$(git tag -l | python -c ' | |
| 7 import sys, re | |
| 8 version_re = re.compile(r"^(.*/)?(v[0-9.]+)$") | |
| 9 key = lambda m: tuple(map(int, m.group(2)[1:].split("."))) | |
| 10 matches = sorted(dict( | |
| 11 (key(m), m) for m in map(version_re.search, sys.stdin) if m).items()) | |
| 12 print "%s..%s" % (matches[-2][1].group(0), matches[-1][1].group(0)) | |
| 13 ') | |
| 14 | |
| 15 echo $REV_RANGE | |
| 16 | |
| 17 # Canonicalize by BOTH e-mail address and by name. | |
| 18 # e.g. Matias Niemelàˆ (Matias Niemela\xcc\x88) and | |
| 19 # Matias Niemelä (Matias Niemel\xc3\xa4) are the same. | |
| 20 git log --pretty=tformat:'%ae %an' "$REV_RANGE" | python -c ' | |
| 21 import sys | |
| 22 authors = set(dict(line.split(" ", 1) for line in sys.stdin).values()) | |
| 23 print ", ".join(sorted(authors)).replace("\n", "") | |
| 24 ' | |
| OLD | NEW |