Re: [PATCH 0/2] 'git svn info' fixes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Thomas Rast <trast@xxxxxxxxxxxxxxx> wrote:
> Eric Wong wrote.
> > > So should we just change all "unknown foo" tests to verify that 'git
> > > svn info' errors out too?
> >
> > Yes, I see no reason to differ from plain svn here.
> 
> This starts getting more complicated at every turn.  The included
> mini-series (probably textually depends on the other 6 patches though)
> "fixes" this.
> 
> HOWEVER: Subversion itself broke compatibility here.  In 1.4:
> 
>   $ svn info new; echo $?
>   new:  (Not a versioned resource)
> 
>   0
> 
> Note the extra linebreak and successful exit.  Current git-svn
> precisely matches this output.  In 1.5, it's different:
> 
>   $ svn info new; echo $?
>   svn: 'new' is not under version control
>   1
> 
> While it is of course up to you what you would like to do (and modulo
> test_must_fail, 2/2 can still be used to fix the tests if you decide
> to reject 1/2), I suggest changing to 1.5 behaviour.  exit(1) is the
> sane thing to do in this case, and that is already breaking
> bit-for-bit compatibility with SVN 1.4, so we might as well adopt the
> new error message.  Of course this prevents us from comparing the
> output literally in the tests, so I settled for a slightly weaker
> check: failure status and mention of the filename.

Yes.  Please maintain compatibility with svn 1.5.  The current version
of git-svn should strive to maintain compatibility with the current
version of svn whenever possible.

> Unfortunately this does raise the question whether the URL-encoding
> issue treated in the other series is in fact a similar incompatibility
> between 1.4 and 1.5, not a (minor but long-standing) bug in git-svn.

It should match svn 1.5 for "git svn info".

Since "git svn info --url" is a git-svn-only thing, whatever makes the
most sense from a command-line scripting perspective (I don't have time
to check against a real repo right now):

For git-svn info --url, just want things like:

	svn log -v `git svn info --url`

	svn cp `git svn info --url` \
               `git svn info --url | sed -e 's,/trunk,/tags/1.0,'`

	svn rm `git svn info --url`

to just work.

I seem to recall the rules being slightly different for http(s):// and
(file://|svn://) URLs with the command-line client; but my memory may
just be fuzzy...

Thanks for looking into this!

-- 
Eric Wong
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux