From: David Kastrup <dak@gnu.org>
To: git@vger.kernel.org
Subject: Re: [RFC] Refspec patterns with * in the middle
Date: Tue, 03 Mar 2009 17:25:48 +0100 [thread overview]
Message-ID: <863aduo9o3.fsf@lola.quinscape.zz> (raw)
In-Reply-To: 7vsklvlcyy.fsf@gitster.siamese.dyndns.org
Junio C Hamano <gitster@pobox.com> writes:
> Daniel Barkalow <barkalow@iabervon.org> writes:
>
>> The issue, in my case, is importing from a system where branches contain
>> projects instead of projects containing branches (and everything is a
>> single namespace). So I want to match an insane (for us) LHS with a sane
>> RHS to get stuff into reasonable shape. I don't really care about any
>> patterns where the branch identifier is multiple components, but I
>> wouldn't be surprised if somebody did.
>
> Isn't this just getting more and more insane? Is this really worth
> supporting, I have to wonder...
>
>> Oh, and it looks like "?" is reserved and currently unused, so we could
>> have * match one or more full path components, and ? match partial path
>> components.
>
> Well, "?" is not allowed exactly because it often is used to match a
> single character by things like for-each-ref.
Let me present a use case where the current matching rules have changed
working well at some point of time.
We have a product called dsp which sits in Subversion under the top
server repository as
dsp/{trunk,branches,tags}
Then we have projects that have a structure including
projekte/some-project/{trunk,branches,tags}/dsp
which usually is an external link to dsp/trunk. However, sometimes a
project needs its own local variations of dsp, in which case
projekte/some-project/trunk/dsp becomes a properly populated copy of
dsp/trunk.
Now in git, I want to track those non-externals as branches of the dsp
checkout: that way I get cherry-picking and merging and stuff like that.
To have this work out, I need to have the dsp git project pulling stuff
from any projekte/some-project/trunk/dsp as a branch called
some-project.
I had a git-svn configuration at one point of time that did that, but
the matching rules have changed since then.
So in this case, the existing Subversion structure (which makes quite
good sense) makes wildcards in non-terminal positions desirable.
--
David Kastrup
next prev parent reply other threads:[~2009-03-03 16:27 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-03-01 23:42 [RFC] Refspec patterns with * in the middle Daniel Barkalow
2009-03-02 12:54 ` Jay Soffian
2009-03-02 17:08 ` Junio C Hamano
2009-03-02 18:01 ` Jay Soffian
2009-03-02 18:25 ` Daniel Barkalow
2009-03-02 22:07 ` Jay Soffian
2009-03-02 22:39 ` Junio C Hamano
2009-03-02 22:58 ` Jay Soffian
2009-03-02 23:00 ` Daniel Barkalow
2009-03-02 23:30 ` Junio C Hamano
2009-03-03 16:25 ` David Kastrup [this message]
2009-03-02 18:22 ` Daniel Barkalow
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=863aduo9o3.fsf@lola.quinscape.zz \
--to=dak@gnu.org \
--cc=git@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox