git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Thomas Guyot-Sionnest <tguyot@gmail.com>
To: "Andreas Grünbacher" <andreas.gruenbacher@gmail.com>
Cc: Konstantin Ryabitsev <konstantin@linuxfoundation.org>,
	Git Mailing List <git@vger.kernel.org>
Subject: Re: Apply git bundle to source tree?
Date: Sat, 19 Sep 2020 08:06:01 -0400	[thread overview]
Message-ID: <CALqVohesf8WA_+_EaZiheoQ=-JL2Lnh_P1GF4MOZV2usVM=-jQ@mail.gmail.com> (raw)
In-Reply-To: <CAHpGcMJy=0deaByZ=jXHRiHgHH7utHc0JTG=BMq9Yf1DOKvuGw@mail.gmail.com>

On Fri, 18 Sep 2020 at 17:45, Andreas Grünbacher
<andreas.gruenbacher@gmail.com> wrote:
>
> Am Fr., 18. Sept. 2020 um 22:18 Uhr schrieb Konstantin Ryabitsev
> >
> > I know this is not what you are asking, but since you used the kernel
> > as your example, you can use the following to achieve the result
> > you're looking for:
> > curl --header 'Accept-Encoding: gzip' -L
> > https://git.kernel.org/torvalds/p/v5.9-rc1/v5.8 | gunzip - | git apply
>
> Oh, that's neat.
>
> What I had in mind were actually distro packages: most projects
> nowadays live somewhere in git repositories. When they're packaged,
> this usually results in a source package with a diff on top of a
> baseline release, so the commit history is lost. Friendly packagers
> include the commit hashes and point users to a suitable git
> repository, but that's not enforced or consistent. Including the
> actual git history in packages would be much nicer (i.e., a git
> bundle), but if that can't replace the patch as well, it's rather
> unlikely to happen.

Afaik a git bundle can do all that, and it's actually a neat idea. It
will be bigger initially than a single release, especially if the
project has not been good at keeping history tidy, but bundles could
be used for both the base release *and* patches, and actually when you
need the next version old bundles could also help downloading just the
additional bits you need.

Since you mentioned it, patches that are maintained by packagers are
best maintained in git already, so the patchset could be available in
a bundle (you can have a single bundle with multiple refs; the
release, the patchset head (each parent back to release HEAD is a
patch) or even each individual patches is that suits you). If you
maintain them as separate bundles, you will always need the release
one for the rest to become useful, but in the end it's easy to convert
between bundles and patches.

FWIW I've been using bundles since the very beginning - my use case
though was backups. I figured it was an efficient way to archive an
entire bare repo into a single file and ship it offsite. I don't think
I kept the script but it's quite simple; bundle just needs the
heads/tags - without a range it goes all the way through history. For
the restore, I would list the heads from the bundle then fetch each
back into the right head/tag in an empty repo.

--
Thomas

  reply	other threads:[~2020-09-19 12:08 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-18 11:13 Apply git bundle to source tree? Andreas Grünbacher
2020-09-18 14:02 ` Taylor Blau
2020-09-18 14:12   ` Andreas Grünbacher
2020-09-18 14:17     ` Taylor Blau
2020-09-18 14:50       ` Andreas Grünbacher
2020-09-18 15:21         ` Andreas Schwab
2020-09-18 15:32           ` Andreas Grünbacher
2020-09-18 15:52             ` Andreas Schwab
2020-09-18 15:41 ` Junio C Hamano
2020-09-18 20:00   ` Andreas Grünbacher
2020-09-18 20:18 ` Konstantin Ryabitsev
2020-09-18 21:45   ` Andreas Grünbacher
2020-09-19 12:06     ` Thomas Guyot-Sionnest [this message]
2020-09-19 19:28     ` brian m. carlson

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

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CALqVohesf8WA_+_EaZiheoQ=-JL2Lnh_P1GF4MOZV2usVM=-jQ@mail.gmail.com' \
    --to=tguyot@gmail.com \
    --cc=andreas.gruenbacher@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=konstantin@linuxfoundation.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.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).