Re: [PATCH 1/2] git-svn: Fix the commit-url config to be the base url, just like the url config
On 04/04/2011 06:54 PM, Eric Wong wrote:
Show 28 quoted lines
> James Y Knight <jknight@itasoftware.com> wrote:
>> > On Apr 4, 2011, at 5:52 PM, Eric Wong wrote:
>>> > > $_commit_url is a user-specified parameter from the --commit-url switch.
>>> > > If they want to override it it's the user's perogative. It's not the
>>> > > default and not commonly used.
>> >
>> > In .git/config:
>> >
>> > [svn-remote "svn"]
>> > url = http://hostname/svnrepo/
>> > commiturl = svn+ssh://hostname/svnrepo
>> > branches = branches/*:refs/remotes/origin/*
>> > fetch = trunk:refs/remotes/origin/master
>> >
>> > The commiturl configuration is necessary so that the canonical URL is the http:// url (which can be used for read-only access), but if you want to commit, you have to use svn+ssh. This is a fairly common way of setting up access to an svn repository, so I'm surprised to be the first one to hit this issue.
>> >
>> > Without the patch, you need:
>> > commiturl = svn+ssh://hostname/svnrepo/trunk
>> > which of course then doesn't allow you to commit to other branches.
> Originally --commit-url was only intended to be a command-line option
> and for overriding specific cases and also for dealing with permission
> mismatches (limited commit access to a branch, unlimited read access
> to the repo).
>
> Your patch breaks existing use cases, I think.
>
> I think Junio's suggestion for a pushurl config which does what you
> think commitUrl does would be what you're after...
That sounds good to me. I'll submit an updated patch later today.
-Alejandro