repo简单使用

来源:互联网 发布:mac怎么设置默认系统 编辑:程序博客网 时间:2024/06/08 06:52

下载repo

#访问不了google,所以从github下载镜像git clone https://github.com/android/tools_repo.git #我用的是ubuntu15.10,直接用apt-get下载就可以了sudo apt-get install repo

修改REPO_URL

REPO_URL = 'https://gerrit.googlesource.com/git-repo'REPO_URL = 'https://gerrit-google.tuna.tsinghua.edu.cn/git-repo'

初始化版本库

mkdir workspace && cd workspacerepo init -u https://android.googlesource.com/platform/manifest#使用清华大学 AOSP 镜像repo init -u git://aosp.tuna.tsinghua.edu.cn/aosp/platform/manifest#如果只需要某个分支repo init -u https://aosp.tuna.tsinghua.edu.cn/platform/manifest -b android-6.0.1_r9

同步源码树(以后只需执行这条命令来同步):

repo sync

参考

  • http://source.android.com/source/using-repo.html
  • https://mirrors.tuna.tsinghua.edu.cn/help/#AOSP
  • http://source.android.com/source/downloading.html
  • repo about .git/HEAD: error: manifest missing or unreadable
0 0
原创粉丝点击