post-review: teach GitClient to be flexible

Review Request #935 — Created July 26, 2009 and discarded — Latest diff uploaded

Information

djs
Review Board SVN (deprecated)

Reviewers

MOVED TO http://reviews.review-board.org/r/985/


This adds more robust support for git to post-review, so now I'll actually start using it myself. You should now be able to provide any arbitrary diff for review as long as you don't do something crazy like modify your local upstream to not match the remote.

 * Add --upstream option to select the upstream repository, instead of hard-coding origin (origin is default)
 * Remove all references to master branch. We now diff against the remote name
 * diff_between_revisions is implemented
 * git-svn now diffs against git-svn remote (equivalent to upstream in pure git) instead of 'master'

I don't use git-svn much, so someone with more experience should test this out. I also noticed after the fact that there are several related changes under review:
http://reviews.review-board.org/r/793/
http://reviews.review-board.org/r/889/
Manual testing:

 * post-review with no options
 * post-review with --upstream specified
 * post-review with --parent specified
 * post-review with --revision-range specified
 * Posted this diff with this version :)