Re: Is git-svn supposed to work with --parent?

2010-07-15 Thread Jared Roberts
Hmm, I can't tell if the groups web interface ate my message or if I
just need mod approval before it shows up so I'll try again.  Sorry if
this shows up twice.

change-3 and change-2 *are* branches, just with a single commit each.
Sorry I didn't make that clear (note the presence of refs/heads/
change-3 in the log).  Ideally, it would be awesome if someday I could
say --parent=HEAD^ or something like that, but it's easy enough to
make new branches as a workaround so it's not a huge deal.  Thanks for
you help.

-- 
Want to help the Review Board project? Donate today at 
http://www.reviewboard.org/donate/
Happy user? Let us know at http://www.reviewboard.org/users/
-~--~~~~--~~--~--~---
To unsubscribe from this group, send email to 
reviewboard+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/reviewboard?hl=en


Re: Is git-svn supposed to work with --parent?

2010-07-15 Thread Jared Roberts
Sorry I wasn't clear: change-3 and change-2 *are* branches, with a
single commit each (hence the refs/heads/change-3 in the log).  It
would be ideal if they didn't have to be, but it's an easy workaround
so I'll take whatever I can get.

-- 
Want to help the Review Board project? Donate today at 
http://www.reviewboard.org/donate/
Happy user? Let us know at http://www.reviewboard.org/users/
-~--~~~~--~~--~--~---
To unsubscribe from this group, send email to 
reviewboard+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/reviewboard?hl=en


Re: Is git-svn supposed to work with --parent?

2010-07-14 Thread Christian Hammond
Hi Jared,

Can you tell me if this works when using branches instead of revisions?

I'm not entirely sure if git-svn works with parent branches, but I thought
it did. It *should* be generating a diff between the SVN repository and the
branch and sending that as a parent diff along with the generated diff. You
won't see this parent diff with --output-diff though.

Christian

-- 
Christian Hammond - chip...@chipx86.com
Review Board - http://www.reviewboard.org
VMware, Inc. - http://www.vmware.com


On Wed, Jul 14, 2010 at 10:55 AM, Jared Roberts jar...@gmail.com wrote:

 I'm new to reviewboard, so maybe I have totally the wrong idea.  My
 org uses svn, but I'm using git-svn.  I have a chain of commits in my
 git repos, and I want to post them as separate review requests, but I
 can't seem to get post-review to do this.

 My git repos looks like this:

 O -- change-3
 |
 O -- change-2
 |
 O -- change-1
 |
 O -- master -- remotes/trunk

 I want to be able to do something like:

 git checkout change-3
 post-review --parent=change-2

 and post a diff between change-2 and change-3 for review (ideally,
 just saying post-review HEAD^ HEAD would be even better), even
 though the repository from reviewboard's point of view is SVN.

 I've seen some discussion that seems to suggest that this ought to
 work:
 http://groups.google.com/group/reviewboard/browse_thread/thread/3423e2c8f71c5c3a?pli=1

 but it doesn't for me :(.  It appears I'm getting empty diffs?

 $ git checkout change-3
 $ post-review --parent=change-2
 Traceback (most recent call last):
  File /usr/local/bin/post-review, line 8, in module
load_entry_point('RBTools==0.2', 'console_scripts', 'post-review')
 ()
  File build/bdist.linux-x86_64/egg/rbtools/postreview.py, line
 2861, in main
  File build/bdist.linux-x86_64/egg/rbtools/postreview.py, line
 2554, in tempt_fate
  File build/bdist.linux-x86_64/egg/rbtools/postreview.py, line 503,
 in upload_diff
 TypeError: object of type 'NoneType' has no len()


 $ post-review --parent=change-2 --output-diff  --tracking-branch=trunk
 -d
  svn info
  git rev-parse --git-dir
  git symbolic-ref -q HEAD
  git svn info
  repository info: Path: https://dev.pluggd.com/svn, Base path:
 /frontend/HtmlClient/Player/trunk, Supports changesets: False
  git config --get reviewboard.url
  git merge-base change-2 refs/heads/change-3
  git diff --no-color --no-prefix -r -u change-2..
  git svn find-rev change-2
  git diff --no-color --no-prefix -r -u
 dae96a154b9f395a9945b833973654d813ea8e5f..change-2
  git svn find-rev dae96a154b9f395a9945b833973654d813ea8e5f
 None

 dae96a.. is change-2, so it makes sense that the diff is empty.  It
 should also be noted that the git svn find-rev change-2 doesn't
 return anything, since change-2 isn't in svn.  As a last thrash, I
 tried modifying postreview.py's GitClient.make_svn_diff, and added:

 if not rev:
rev = execute([git, svn, find-rev,
 options.tracking]).strip()

 after the first line that tries to find the parent's svn rev.  This
 makes post-review generate the right diff!  But if I post it to review
 board, I can't view it, presumably because it's trying to apply it
 against the version in svn.  Here I gave up.

 Is there a solution?

 --
 Want to help the Review Board project? Donate today at
 http://www.reviewboard.org/donate/
 Happy user? Let us know at http://www.reviewboard.org/users/
 -~--~~~~--~~--~--~---
 To unsubscribe from this group, send email to
 reviewboard+unsubscr...@googlegroups.comreviewboard%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/reviewboard?hl=en

-- 
Want to help the Review Board project? Donate today at 
http://www.reviewboard.org/donate/
Happy user? Let us know at http://www.reviewboard.org/users/
-~--~~~~--~~--~--~---
To unsubscribe from this group, send email to 
reviewboard+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/reviewboard?hl=en