Android repo branch/Partial-clone/--depth=1/--groups

repo init -u https://android.googlesource.com/platform/manifest -b android-4.0.1_r1

repo init -u https://android.googlesource.com/platform/manifest -b  android-9.0.0_r45      (   PQ3B.190705.003  base  version for Android9/RK3399/Firefly )  

At the time of writing,

repo init --depth=1  -u https://android.googlesource.com/platform/manifest -b android-5.1.0_r5

creates 33GB worth of files.

Adding --depth=1 reduces this to 21GB.

Adding --groups=all,-notdefault,-device,-darwin,-x86,-mips,-exynos5 to exclude devices and components you're not interested in reduces this to 19GB.

For storage only, you could remove the checked-out files for each .git repository inside .repo/ to save even more space, but I'm not sure how to script this. If you did do this, repo sync would check out the "missing" files when needed.

For reference, my complete command line was
repo init -u https://android.googlesource.com/platform/manifest -b android-5.1.0_r5 --depth=1 --groups=all,-notdefault,-device,-darwin,-x86,-mips,-exynos5,mako

Code Name refer to 

https://source.android.com/setup/start/build-numbers

https://blog.csdn.net/hushui/article/details/83305863 

##  Partial-clone/git2.19 

If using Git version 2.19 or greater, you can specify --partial-clone when performing repo init which will make use of Git's partial clone capability, which only downloads Git objects when needed instead of downloading everything. Because using partial clones means that many operations need to communicate with the server, this is recommended for developers who are using a network with low latency:

repo init -u https://android.googlesource.com/platform/manifest -b master --partial-clone --clone-filter=blob:limit=10M

If using Git version 2.19 or greater, you can specify --partial-clone when performing repo init which will make use of Git's partial clone capability, which only downloads Git objects when needed instead of downloading everything. Because using partial clones means that many operations need to communicate with the server, this is recommended for developers who are using a network with low latency:

猜你喜欢

转载自blog.csdn.net/hushui/article/details/112727873