Reducing amount of download size by copying the existing repository
If you have already downloaded old source code (for example, android-2.2_r1.1), you can reduce amount of newly download size to use old repository. so you download only the difference.
$ mkdir android-2.3 $ cd android-2.3/ $ repo init -u git://android.git.kernel.org/platform/manifest.git -b android-2.3.4_r1 $ cp -R ../android-2.2_r1.1/.repo/projects .repo/ $ repo sync
If you can overwrite the existing working directory,
$ mv android-2.2_r1.1 android-2.3 $ cd android-2.3 $ repo init -b android-2.3.4_r1 $ repo sync
I got this knowledge from Google group of Android Building(how do I switch branches by repo).
Option to run repo sync parallely
"make" command has '-j' option to run multi jobs parallely. "repo sync" has similar option, too.
Let's examine command line help.
$ repo sync -h Usage: repo sync [...] Options: -h, --help show this help message and exit -f, --force-broken continue sync even if a project fails to sync -l, --local-only only update working tree, don't fetch -n, --network-only fetch only, don't update working tree -d, --detach detach projects back to manifest revision -q, --quiet be more quiet -j JOBS, --jobs=JOBS number of projects to fetch simultaneously -s, --smart-sync smart sync using manifest from a known good build repo Version options: --no-repo-verify do not verify repo source code $
If you want to run 4 fetching jobs pararellely,
$ repo sync -j4This can reduce the download time. However, be sure not to occupy the bandwidth of the network.
No comments:
Post a Comment