Skip to content

RFC Implement git shallow mirror tarball support

Christopher Larson bitbake-devel 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 RFC Latest5 patches 10 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/5bb.fetch.git: add support for shallow mirror tarballslib/bb/fetch2/git.py+125 -400 replies
2/5bb.fetch.git: truncate branches to SRCREVlib/bb/fetch2/git.py+5 -00 replies
3/5bb.fetch: simplify mirror tarball handling in try_mirror_urllib/bb/fetch2/__init__.py+2 -30 replies
4/5bb.fetch: support ud.mirrortarballslib/bb/fetch2/__init__.py+13 -90 replies
5/5bb.fetch.git: use ud.mirrortarballslib/bb/fetch2/git.py+31 -250 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [RFC PATCH 0/5] Implement git shallow mirror tarball support

From: Christopher Larson <[email protected]>

Please review the following changes for suitability for inclusion. If you have any objections or suggestions for improvement, please respond to the patches. If you agree with the changes, please provide your Acked-by.

This only implements support for shallow mirror tarballs, not shallow clones.

The mirror tarball filename includes branch, revision, and depth. To enable, use the BB_GIT_SHALLOW variable, or BB_GIT_SHALLOW_<name> for specific URLs. This variable can hold either a clone depth (e.g. 1 to just get SRCREV), or a ref or commit, in which case we keep history up to that commit.

The shallow support will not, at this time, function correctly for linux-yocto, due to its branching scheme & validation.

Example:

BB_GIT_SHALLOW ?= "1"
BB_GIT_SHALLOW_pn-linux-yocto = ""
BB_GIT_SHALLOW_pn-linux-mel_mx6 = "v3.14"
BB_GIT_SHALLOW_pn-testrepo = "testbranch"

This implementation will attempt to fetch a full mirror tarball if it was unable to fetch a shallow tarball. If BB_GIT_SHALLOW and BB_GENERATE_MIRROR_TARBALLS are enabled for a given recipe, a shallow tarball will be emitted.

The following changes since commit 0c419902e5f58dcee9b7fbe9af1928da37e18399:

toaster: reduced amount of instance attributes (2015-08-10 13:56:03 -0700)

are available in the git repository at:

[email protected]:kergoth/bitbake shallow-git-mirror-tarballs

for you to fetch changes up to 01c1164fe4b54d5f3de1fd4863808af88f06c144:

bb.fetch.git: use ud.mirrortarballs (2015-08-13 15:48:01 -0700)

----------------------------------------------------------------
Christopher Larson (5):
bb.fetch.git: add support for shallow mirror tarballs bb.fetch.git: truncate branches to SRCREV bb.fetch: simplify mirror tarball handling in try_mirror_url bb.fetch: support ud.mirrortarballs
bb.fetch.git: use ud.mirrortarballs

 lib/bb/fetch2/__init__.py |  27 ++++---
 lib/bb/fetch2/git.py      | 182 +++++++++++++++++++++++++++++++++++-----------
 2 files changed, 154 insertions(+), 55 deletions(-)
Signature · 1 line
2.2.1