这个是Android源码镜像源
https://mirrors.tuna.tsinghua.edu.cn/help/AOSP/
PATH=~/bin:$PATH
git clone https://aosp.tuna.tsinghua.edu.cn/platform/manifest
$ cd manifest
$ repo init -u https://android.googlesource.com/platform/manifest -b android-2.2.2_r1
把https://android.googlesource.com/
全部使用 https://aosp.tuna.tsinghua.edu.cn/
1下载repo源码管理脚本
PATH=~/bin:$PATH
curl https://storage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
chmod a+x ~/bin/repo
下面这个在repo中更改下
下载git仓库Android清单
git clone https://android.googlesource.com/platform/manifest可全部替换为下面的git clone https://aosp.tuna.tsinghua.edu.cn/platform/manifest
$ cd manifest
$ git branch -a 可以查看当前的分支
$ repo init -u https://android.googlesource.com/platform/manifest -b android-2.2.2_r1
替换为 repo init -u https://aosp.tuna.tsinghua.edu.cn/platform/manifest -b android-4.1.1_r3
$ repo sync
下载内核goldfish源码清单
git clone https://aosp.tuna.tsinghua.edu.cn/aosp/kernel/goldfish.git
cd goldfish查看分支
git branch -a
git checkout -b remotes/origin/android-goldfish-2.6.29