# Google Code
repo init -u https://android.googlesource.com/platform/manifest -b android-11.0.0_r40 --depth=1
git clone https://github.com/AOSP-11/local_manifests .repo/local_manifests -b 11
# 同步源码
repo sync -c -j$(nproc --all) --force-sync --no-clone-bundle --no-tags
# Set up environment
$ . build/envsetup.sh
# Choose a target
$ lunch aosp_$device-userdebug
# Build the code
$ brunch $device
$ repo init -b android-11.0.0_r40