git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCHv2 0/4] git-p4: small fixes to branches and labels; tests

From
PWPete Wyckoff <pw@padd.com>
Date
Dec 1, 2011, 04:02 UTC
Message-ID
<20111201040259.GA22189@arf.padd.com>
In-Reply-To
<CAOpHH-U3PF0v7EPqnO0FNxNKh+uF1GH=cnA_MA09SaQTxo0cDA@mail.gmail.com>
vitor.hda@gmail.com wrote on Thu, 01 Dec 2011 00:33 +0000:
Show 16 quoted lines
> On Wed, Nov 30, 2011 at 10:58 PM, Pete Wyckoff <pw@padd.com> wrote:
> > This is another fundamental disconnect between p4 and git.
> > Reading
> >
> > http://www.perforce.com/perforce/doc.current/manuals/p4guide/07_labels.html
> >
> > it is clear that labels are supposed to be used exactly where
> > tags cannot:  to specify a collection of files as they existed
> > at _different_ points in the commit history.
> 
> Check the "Use Tag Fixup Branches" section in fast-import manual, it
> might help on this. The basic concept is to create a special branch
> that puts all files in the same state the P4 label would put them and
> then tag it in git.
> 
> Tried to use this for my branch stuff, but with no success.

Interesting, thanks. One could certainly construct any arbitrary tree to represent the tag. But it would be a truly evil merge of possibly many commits.

Show 9 quoted lines
> > Thus I think supporting labels is kind of pointless.  But in the
> > restricted use case that perforce docs tell us not to do, namely
> > using labels to identify change numbers, git can reflect that
> > with tags.
> 
> I still use labels as simple tags. Telling that we should use
> changelists instead of labels is the same as saying that we should use
> IP addresses instead of host names. It works, but I doubt you will
> ever remember it unless you write it down somewhere.

I see your point. P4 labels are the only way that they support tagging, apparently. I'm okay with leaving label support in git-p4. And it will be nice if Luke makes it behave a bit better. But doing heroics to emulate cross-commit tags feels like a lot of work, and the wrong direction.

		-- Pete
Previous: Vitor AntunesNext: Vitor Antunes
Message 15 of 17 in “[PATCHv2 0/4] git-p4: small fixes to branches and labels; tests”
  1. Luke DiamandNov 30, 2011
  2. 1/4 git-p4: handle p4 branches and labels containing shell charsLuke Diamand, Nov 30, 2011
  3. 2/4 git-p4: cope with labels with empty descriptionsLuke Diamand, Nov 30, 2011
  4. 3/4 git-p4: importing labels should cope with missing ownerLuke Diamand, Nov 30, 2011
  5. 4/4 git-p4: add test for p4 labelsLuke Diamand, Nov 30, 2011
  6. Vitor AntunesNov 30, 2011
  7. Luke DiamandNov 30, 2011
  8. Vitor AntunesNov 30, 2011
  9. Pete WyckoffNov 30, 2011
  10. Pete WyckoffNov 30, 2011
  11. Vitor AntunesDec 1, 2011
  12. Pete WyckoffDec 4, 2011
  13. Luke DiamandDec 1, 2011
  14. Vitor AntunesDec 1, 2011
  15. Pete WyckoffDec 1, 2011
  16. Vitor AntunesDec 1, 2011
  17. Luke DiamandDec 2, 2011

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.