I was looking at a bug report about old software, and wanted to see what development branch a quoted commit was on:
anholt@eliezer:anholt/src/mesa-release% git describe 97217a40f97cdeae0304798b607f704deb0c3558 snb-magic-15797-g97217a4 That's... not terribly useful. It would be nice if git describe could be used so I could figure out what development branch a commit was for. So I wrote a little script: branchpoint=`git rev-list origin/master..origin/$@ | tail -n 1` git tag -f -s -m "Mesa $@ branchpoint" $@-branchpoint $branchpoint~ and generated a bunch of tags in my repo: 10.0-branchpoint 10.1-branchpoint 7.10-branchpoint 7.11-branchpoint 7.8-branchpoint 7.9-branchpoint 8.0-branchpoint 9.0-branchpoint 9.1-branchpoint 9.2-branchpoint which look like: tag 10.1-branchpoint Tagger: Eric Anholt <e...@anholt.net> Date: Thu Mar 27 23:59:46 2014 -0700 Mesa 10.1 branchpoint -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAABCAAGBQJTNR3iAAoJELXWKTbR/J7ovjkP/0IbzY1BMcyIAEwKKTDwPKbk wPalZWYZiPsMozbie8crJS4GIciDGktsMWzVF0PwHL3FxaRqmGvZysvrT6UgWWg/ ySWZ9yApW3kVYrH0dQplQhqnpe/xalx2ooWGJX44ZL71KDg8BOCZ9+JC7JG4/pU2 Rl0dmBhmepXiKYvhfl53voggaZldPL5U3yN2mtXh5uzBw1IoHco8C9iwbsijzwIw KGSbYV+cHsmdu5k2xnLJQu9Tr/1dH4yuYjNy6MshCweOwj0T+x3qw2gURUOAkyz0 NSRrQM8IO9ACvr0uFsF69mVya8/76lNXhxbRgLFk4CEcrLi+2SbH1/ozzgTWniQw 6FKOqoQOA8VxNek8oH7r48RAATe34RkhcDqyrG2cEAnSzYFsqwVCT+kWoxFdAAcR mIDi6xOD/FtotylWUuQFS6UBb0iDNS9o1S+OzBBq+nBYGgezRsxpsVyALHYLJ1QF ZD+qVikZdHbgP4npjFHkgx08z3cNM5Qk/X4VWwT9DlaI+bdDqTx7z+d2o7nWkvTv UOO4UPEQESFsova2LnOBd+wg3zomH+StY3c0LhEfkE6tUXP7JjjBVMoMLWtVAJ5D dhcI0pXSS6vbafKVb2g3BTY2/ZtmJmNBXc4OwJFPEttHP69c3dXJ8W2yTT+GbvOK VR9vzInQ2Rgd9F20XZ1B =m5VJ -----END PGP SIGNATURE----- And now git describe command tells me: anholt@eliezer:anholt/src/mesa% git describe 97217a40f97cdeae0304798b607f704deb0c3558 9.1-branchpoint-1412-g97217a4 So now I know that this commit came after we forked off 9.1 (thus, it's going to be in the 9.2 branch for sure). Would others like to see these tags in the main repo? I would be happy to push them. And would whoever forks the release branch want to do this command in the future? I guess this isn't the only way we could generate tags for making git-describe useful. For example, you could run a similar script to generate a tag just *after* the branchpoint identified here, along master, so that git-describe would say "9.2-devel-1412-g97217a4" or whatever for that commit, but "9.1-branchpoint-2-gaf2d8f8" for af2d8f8072c53d4c63ed22b74f78213c1181c1eb for an early commit on the 9.1 branch.
pgphIZqnbdaCy.pgp
Description: PGP signature
_______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev