git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Grant Erickson <gerickson@nuovations.com>
To: Casey Dahlin <cdahlin@redhat.com>
Cc: <git@vger.kernel.org>
Subject: Re: GIT and Cloning Remote Repositories into "Local Remote" Repositories
Date: Sun, 26 Sep 2010 18:17:45 -0700	[thread overview]
Message-ID: <C8C53EC9.1E621%gerickson@nuovations.com> (raw)
In-Reply-To: <20100921013700.GC8380@foucault.redhat.com>

On 9/20/10 6:37 PM, Casey Dahlin wrote:
> On Mon, Sep 20, 2010 at 06:22:09PM -0700, Grant Erickson wrote:
>> Perhaps 'submodules' are what I am looking for?
>> 
> 
> Yup, exactly :) the manpage git submodule should get you going.

Casey:

Thanks for the prompt reply.

I spent some time over the weekend playing with the various submodule
tutorials and I wasn't left feeling convinced that it's the right solution,
particularly with the added complexity around commits and pushes (trailing
slashes, etc.) that I am sure my users are going to get wrong more often
than right.

In further explorations, it occurred to me that the "subtree" merge strategy
might be another, perhaps, better alternative. However, when I tried it
based on the example at
http://www.kernel.org/pub/software/scm/git/docs/howto/using-merge-subtree.ht
ml, I got some results that were unexpected, such as files showing up where
I didn't want them to: top-of-tree rather than the intended subdirectory.

Basically, I am starting out a project with x-loader, u-boot and linux based
on the Arago project GIT at tag OMAPPSP_03.00.01.06, from which TI's
somewhat-dated PSP is based:

    git://arago-project.org/git/projects/x-load-omap3.git
    git://arago-project.org/git/projects/u-boot-omap3.git
    git://arago-project.org/git/projects/linux-omap3.git

At some point, once my system is stable, I'd like to merge both u-boot and
linux up to mainline revisions/tags with my local changes included from:

    git://git.denx.de/u-boot.git
    git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git

My tree is organized roughly as:

    root/
        .git/
        fw/
            u-boot/
                Makefile
                u-boot/
                    <Actual contents of GIT tree here>
            x-loader/
                Makefile
                x-loader/
                    <Actual contents of GIT tree here>
        sw/
            tps/
                linux/
                    Makefile
                    linux/
                        <Actual contents of GIT tree here>

My ideal workflow would be:

    1) Merge Arago GIT git://arago-project.org/git/projects/u-boot-omap3.git
to root/fw/u-boot/u-boot/.
    2) Make local changes.
    3) % git commit ...
       % git push <to GitHub repo master>
    4) Make more local changes.
    5) % git commit ...
       % git push <to GitHub repo master>
    6) Ad infinitum until local changes are stable
    7) Merge Denx GIT git://git.denx.de/u-boot.git @ v2010.09-rc2 to
root/fw/u-boot/u-boot/.
       % git <something> ...
    8) Resolve conflicts, commit and push to GitHub repo master.

And so on for the linux subtree as well. Any further tips or course
corrections you can offer, particularly relative to subtree merges?

Best,

Grant

  reply	other threads:[~2010-09-27  1:18 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-09-21  1:22 GIT and Cloning Remote Repositories into "Local Remote" Repositories Grant Erickson
2010-09-21  1:37 ` Casey Dahlin
2010-09-27  1:17   ` Grant Erickson [this message]
2010-09-27 15:18     ` Casey Dahlin
2010-09-27 15:29       ` Grant Erickson
2010-09-21  4:26 ` Tay Ray Chuan

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=C8C53EC9.1E621%gerickson@nuovations.com \
    --to=gerickson@nuovations.com \
    --cc=cdahlin@redhat.com \
    --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;
as well as URLs for NNTP newsgroup(s).