From: Victor Engmark <victor.engmark@gmail.com>
To: Jon Seymour <jon.seymour@gmail.com>
Cc: git@vger.kernel.org
Subject: Re: RFC: Folder Git
Date: Tue, 26 Apr 2011 08:47:46 +0200 [thread overview]
Message-ID: <BANLkTikkFgCQP9DA5VwMCMzDCiTnEENvOg@mail.gmail.com> (raw)
In-Reply-To: <BANLkTimnyv_+NCc3yOSswJeqHo_zsGwCDA@mail.gmail.com>
On Mon, Apr 25, 2011 at 10:52 AM, Jon Seymour <jon.seymour@gmail.com> wrote:
> On Mon, Apr 25, 2011 at 6:32 PM, Victor Engmark
> <victor.engmark@gmail.com> wrote:
> continue to other repositories.
>>
>> Issues:
>> * Don't know if anyone else has used it. Probably not, so there's
>> bound to be issues (especially since it's been changed quite a bit the
>> last couple days for this RFC).
>>
>
> Victor,
>
> Certainly seems like a common need. I had a similar solution which I
> used for a while.
>
> In the end, however, I found that creating a super-module in the top
> directory that contains
> the other git directories as git submodules allowed me to use a
> standard feature of git to achieve the same effect.
>
> So:
>
> git submodule foreach git gc --aggressive
>
> I know this won't suit every use case, but it does work in an
> environment where the set of repos you are operating on have a degree
> of coherence and it makes sense to set up a submodule for them. In
> this particular case this is the only reason why I use submodules - I
> don't use them for configuration management, for example, simply as a
> handy way to exploit git submodule foreach.
>
> Have you considered using git submodules in this way?
I didn't know you could use them this way, and it's a nicely "Gitonic"
way of doing it. I don't think this would fit my case, since the repos
are not much related and it's a more verbose solution which takes
longer to set up than copying a single script. A compromise could be
to set up a Git alias `sgit="git submodule foreach git"`, if that'll
work as expected.
--
Victor Engmark
next prev parent reply other threads:[~2011-04-26 6:48 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-04-25 8:32 RFC: Folder Git Victor Engmark
2011-04-25 8:52 ` Jon Seymour
2011-04-26 6:47 ` Victor Engmark [this message]
2011-04-26 7:03 ` Jon Seymour
2011-04-25 10:39 ` Jakub Narebski
2011-04-26 6:59 ` Victor Engmark
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=BANLkTikkFgCQP9DA5VwMCMzDCiTnEENvOg@mail.gmail.com \
--to=victor.engmark@gmail.com \
--cc=git@vger.kernel.org \
--cc=jon.seymour@gmail.com \
/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).