git获取Android源码,可以断点续传

来源:互联网 发布:mac所有照片怎么分类 编辑:程序博客网 时间:2024/05/16 00:01

git获取Android源码:


1. git clone git://android.git.kernel.org/ + project path.

2. mkdir mydroid

   cd mydroid
   repo init -u git://android.git.kernel.org/platform/manifest.git
   repo sync

 

git clone获取比较大的源码时, 不能断点续传, 比较恼火.

 

可以使用 git fetch 解决:

    mkdir common

     cd common

     git init

     git fetch http://android.git.kernel.org/common.git

     传完后,

     git branch -a

     git checkout remotes/....

 

如果中间断掉了, 可以直接进入common目录, 继续git fetch就可以续传了.

原创粉丝点击