From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: Steven Rostedt <rostedt@goodmis.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>,
LKML <linux-kernel@vger.kernel.org>
Subject: Re: Missing tags in my local stable git repo
Date: Mon, 10 Dec 2012 13:18:54 -0800 [thread overview]
Message-ID: <20121210211854.GA26470@kroah.com> (raw)
In-Reply-To: <1355172274.17101.250.camel@gandalf.local.home>
On Mon, Dec 10, 2012 at 03:44:34PM -0500, Steven Rostedt wrote:
> On Mon, 2012-12-10 at 11:30 -0800, Linus Torvalds wrote:
>
> > Any tree that is an alternate and ever has *any* objects in it that
> > can become unreachable is a really really really bad idea.
>
> The only alternates that I use are my local copies of stable and your
> tree, which should always be safe.
>
> > Also, you should never *ever* make an alternate object store be
> > *another* alternate object store, and I think that may be the problem
> > in your case. Iirc git doesn't follow alternates recursively. So what
> > can happen is that you got objects in the "middle" alternate, that
> > then get pruned away by "git gc" (because they exist in the origin
> > repository), but they got pruned away from the furthest alternate in
> > the meantime, and now the objects are "two hops" away, and will not
> > ever be seen.
>
> OK, this may be my issue, as my stable.git has my copy of your tree as
> an alternate. Maybe I can merge the two trees. Although I'm not exactly
> sure how to. As I have my copies as both alternates as well as remotes
> for my working repos, to get them to pull everything in with a remote
> update. I have in my copy of the stable.git tree the following in the
> config file:
>
> [remote "stable"]
> url = git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git
> fetch = +refs/heads/*:refs/heads/*
>
> Otherwise I don't get the updates from stable when I do a remote fetch
> of my local copies. Would something like this work?
>
> [remote "origin"]
> fetch = +refs/*:refs/*
> mirror = true
> url = git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
> [remote "stable"]
> url = git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git
> fetch = +refs/heads/*:refs/heads/*
>
> That is, if I have a single linus-stable.git repo that all my other
> repos use as an alternate and a remote, I could have this repo updated
> with:
>
> git fetch
> git remote update stable
>
> and all my other repos will get all the updates from both your tree and
> the stable tree with a single remote update of this copy?
>
> Am I making any sense? ;-)
Kind of, but would would be even easier is if you just have one
"origin", pointing at linux-stable.git, and then every so often just do:
git checkout master
git pull git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
As the master branch of linux-stable.git always is a "clean" linux.git
tree, although it might lag a few -rc releases back if I have forgotten
to update it recently. When it does get updated, all should be fine as
the master branch has no merges from anything else, so it's just a
fast-forward.
That might be simpler overall than the different repos to be pulling
from in different ways.
greg k-h
next prev parent reply other threads:[~2012-12-10 21:18 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-12-10 17:35 Missing tags in my local stable git repo Steven Rostedt
2012-12-10 18:12 ` Greg Kroah-Hartman
2012-12-10 18:39 ` Steven Rostedt
2012-12-10 18:47 ` Steven Rostedt
2012-12-10 19:02 ` Greg Kroah-Hartman
2012-12-10 19:15 ` Steven Rostedt
2012-12-10 19:30 ` Linus Torvalds
2012-12-10 20:44 ` Steven Rostedt
2012-12-10 21:08 ` Linus Torvalds
2012-12-10 21:42 ` Steven Rostedt
2012-12-10 21:50 ` Steven Rostedt
2012-12-10 21:12 ` Andreas Schwab
2012-12-10 21:23 ` Steven Rostedt
2012-12-10 21:16 ` Geert Uytterhoeven
2012-12-10 21:18 ` Geert Uytterhoeven
2012-12-10 21:18 ` Greg Kroah-Hartman [this message]
2012-12-10 21:26 ` Steven Rostedt
2012-12-10 21:28 ` Stephen Rothwell
2012-12-10 21:31 ` Linus Torvalds
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=20121210211854.GA26470@kroah.com \
--to=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=rostedt@goodmis.org \
--cc=torvalds@linux-foundation.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