diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2018-01-28 10:28:54 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2018-01-28 11:20:40 +0000 |
commit | f8126aaf774186a6eaf0bd4067b89c074594886c (patch) | |
tree | afebcd414515a6bc7c43f5092716f60bfe1b2e2c | |
parent | 5f7c6ec785f70beb1a4a1bbc0eb83cfa6cd7740d (diff) | |
download | bitbake-contrib-f8126aaf774186a6eaf0bd4067b89c074594886c.tar.gz |
fetch/git: Add pack-refs command to mirror handling code
We've noticed issues on our infrastucture iterating over the many
tag/branch/head reference files that some git repositories may contain.
By issuing the pack-refs command, we move these all to a single file
which speeds up operations with the mirror repos in the downloads
directory in general.
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r-- | lib/bb/fetch2/git.py | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/bb/fetch2/git.py b/lib/bb/fetch2/git.py index 5ef8cd69e..d34ea1de2 100644 --- a/lib/bb/fetch2/git.py +++ b/lib/bb/fetch2/git.py @@ -363,6 +363,7 @@ class Git(FetchMethod): progresshandler = GitProgressHandler(d) runfetchcmd(fetch_cmd, d, log=progresshandler, workdir=ud.clonedir) runfetchcmd("%s prune-packed" % ud.basecmd, d, workdir=ud.clonedir) + runfetchcmd("%s pack-refs --all" % ud.basecmd, d, workdir=ud.clonedir) runfetchcmd("%s pack-redundant --all | xargs -r rm" % ud.basecmd, d, workdir=ud.clonedir) try: os.unlink(ud.fullmirror) |