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

Re: [PATCH/RFC 1/2] Add 'git subtree' command for tracking history of subtrees separately.

From
Avery Pennarun <apenwarr@gmail.com>
Date
Jul 16, 2009, 22:27 UTC
Message-ID
<32541b130907161527l1955bf06pf54b5099a5988c65@mail.gmail.com>
In-Reply-To
<cdea6cd10907161509g7771c72bl608b1924785b49fc@mail.gmail.com>
On Thu, Jul 16, 2009 at 6:09 PM, Andrey Smirnov<allter@gmail.com> wrote:
Show 17 quoted lines
> On Thu, Jul 16, 2009 at 10:34 PM, Avery Pennarun<apenwarr> wrote:
>> I don't think that's a good idea.  git-subtree is completely separate
>> from rebasing, and doesn't deal with patches at all.  Maybe there
>> should be some kind of "force-update" option that does what "git
>> subtree add" does, but wiping out everything in the subtree before it
>> starts.  That would have simplified the above commands a bit.
>
> The only thing that links git-subtree with git-rebase is the fact, that
> git-subtree "knows" the target commit for rebases dealing with subtrees.
> So if one knows commit of a subtree that he wishes to see in superproject
> (in my case "test-split") he could issue:
>    git subtree rebase --prefix=lib OldProject test-split
>
> Though simple:
>    git rebase --onto OldProject test-split-old test-split
> worked for me, I think this was a lucky coincidence because of simplicity
> of my library commits.

I don't really understand what you're asking for here. rebase doesn't have any parameters called a "target." What does git-subtree know that you don't know?

Have fun,
Avery
Previous: Andrey SmirnovNext: Andrey Smirnov
Message 10 of 13 in “Add 'git subtree' command for tracking history of subtrees separately.”
  1. 1/2 Add 'git subtree' command for tracking history of subtrees separately.Avery Pennarun, Apr 26, 2009
  2. 2/2 Automated test script for 'git subtree'.Avery Pennarun, Apr 26, 2009
  3. Avery PennarunApr 30, 2009
  4. Ping YinApr 30, 2009
  5. Finn Arne GangstadApr 30, 2009
  6. Avery PennarunApr 30, 2009
  7. Andrey SmirnovJul 16, 2009
  8. Avery PennarunJul 16, 2009
  9. Andrey SmirnovJul 16, 2009
  10. Avery PennarunJul 16, 2009
  11. Andrey SmirnovJul 17, 2009
  12. Avery PennarunJul 17, 2009
  13. Andrey SmirnovJul 17, 2009

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.