[Webkit-unassigned] [Bug 26999] bugzilla-tool/svn-apply can't handle patches made from a non-root directory

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Jul 14 18:30:07 PDT 2009


https://bugs.webkit.org/show_bug.cgi?id=26999


David Kilzer (ddkilzer) <ddkilzer at webkit.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #32743|review?                     |review+
               Flag|                            |




--- Comment #12 from David Kilzer (ddkilzer) <ddkilzer at webkit.org>  2009-07-14 18:30:06 PDT ---
(From update of attachment 32743)
(In reply to comment #11)
> (In reply to comment #5)
> > IMO, it would be great to have a replacement subroutine for chdirwebkit() that
> > got the svn URL from the "svn info" command in the current directory, then did
> > a "chdir .." until the current svn URL no longer matched the previous svn URL
> > (minus one directory), then you could chdir back into the last directory.  This
> > would then put you at the root of the svn working directory regardless of
> > whether you're working on WebKit or not.
> 
> The way I went about it was using "svn info [PATH]".  And building up that path
> as a trail of "../".  I also use system() to check the error code of svn info. 
> Let me know if there is a problem with this approach (cross platform?) or if
> you think of a better way and I'll see what I can do.

I thought of doing that after my last comment as well!  The only situation
where this won't work is if a user has a "mixed" svn working directory where
they have one svn working directory at "dir" and a second svn working directory
(from a different repository) under "dir", and the user ran svn-create-patch in
the second working directory.  I don't know how prevalent this use case is, and
I doubt it's common with WebKit, so let's not worry about that for now.

>+sub chdirAndGetDifference($);

Nit: Instead of "GetDifference", I think something like "ReturnRelativePath"
might be more descriptive.  I can change this when I land the patch.

r=me!

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list