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

Re: [PATCH/RFC 2/2] git-p4: Add complex test case for branch import

From
PWPete Wyckoff <pw@padd.com>
Date
Aug 23, 2011, 02:27 UTC
Message-ID
<20110823022713.GA6005@arf.padd.com>
In-Reply-To
<20110822011319.0a013117@fenix.utopia.dhis.org>
vitor.hda@gmail.com wrote on Mon, 22 Aug 2011 01:13 +0100:
> I still need some help on the code part of this RFC patch. I really do
> not like the way it is implemented. Do you see other possible ways of
> achieving the same algorithm?

I think I understand the problem now, and have a small test case to see what's going wrong. Your solution is definitely sub-optimal. :) Is there anything that can be done with --import-marks and --export-marks?

Could you guess at the branch point using p4? I.e. for each file in the new branch, grab the change that caused its most recent revision (the #xx part). Pick the max of those changes. In git, find the commit whith "change = ..." that you just discovered. That's the parent.

Even this won't be perfect, and I'm not even sure if it's less icky than diff-tree.

		-- Pete
Previous: Vitor AntunesNext: Vitor Antunes
Message 6 of 11 in “Search for parent commit in new branch import”
  1. 0/2 Search for parent commit in new branch importVitor Antunes, Aug 19, 2011
  2. 1/2 git-p4: Search for parent commit on branch creationVitor Antunes, Aug 19, 2011
  3. 2/2 git-p4: Add complex test case for branch importVitor Antunes, Aug 19, 2011
  4. Pete WyckoffAug 20, 2011
  5. Vitor AntunesAug 22, 2011
  6. Pete WyckoffAug 23, 2011
  7. Vitor AntunesAug 23, 2011
  8. Pete WyckoffAug 23, 2011
  9. Vitor AntunesAug 24, 2011
  10. Vitor AntunesAug 24, 2011
  11. Pete WyckoffAug 27, 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.