AOSP repo sync takes too long
AOSP is a multi-gigabyte download so there's not that much you can do. However, passing the -c
/--current-branch
option to repo sync
causes Repo to tell Git to only fetch the branch you really need instead of all branches of each repository. With an old release like Gingerbread this should theoretically be quite beneficial. However, Repo seeds the repositories with Git bundles that it downloads via HTTP, and the bundle files aren't affected by the -c
option. Using --no-clone-bundle
disables the bundle files. Hence the following Repo command should yield the smallest download:
repo sync -c --no-clone-bundle
(Keep in mind that Gingerbread is a several year old release. It won't work out of the box on a lot of recent hardware.)
You should use this commands:
Example: for my personal AOSP Repo,
repo init --depth=1 -u https://github.com/zawzaww/aosp-android.git -b android-8.1.0
and then,
repo sync -f --force-sync --no-clone-bundle --no-tags -j$(nproc --all)
You can learn more on my GitHub Repo
repo sync -c --no-tags --no-clone-bundle -j2
Shortens my sync times greatly.