2 slaks SLaks 于 2013.03.21 13:37 提问

检查源代码后,如何切换到一个特定的android版本?

如果我用下面的方法查看 android 源代码

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

如何转换到一个特定的 android 版本?例如1.6版本?

2个回答

wfing
wfing   2013.03.25 08:44
已采纳

由于repo是同时管理的多个git和svn库,单纯用git会出现问题的.

下面是repo的常用功能

[ycwang@ycwang:android-git]$ ./repo 
usage: repo COMMAND [ARGS]

The most commonly used repo commands are:

  abandon      Permanently abandon a development branch
  branch       View current topic branches
  branches     View current topic branches
  checkout     Checkout a branch for development
  cherry-pick  Cherry-pick a change.
  diff         Show changes between commit and working tree
  download     Download and checkout a change
  grep         Print lines matching a pattern
  init         Initialize repo in the current directory
  list         List projects and their associated directories
  prune        Prune (delete) already merged topics
  rebase       Rebase local branches on upstream branch
  smartsync    Update working tree to the latest known good revision
  stage        Stage file(s) for commit
  start        Start a new branch for development
  status       Show the working tree status
  sync         Update working tree to the latest revision
  upload       Upload changes for code review
suannai0314
suannai0314 帮你编辑了下代码的格式,更详细的markdown使用方法见http://ask.csdn.net/pages/markdown
接近 5 年之前 回复
hooopo
hooopo   2013.03.21 14:32
git branch -r

看看都有哪些分支
然后git checkout -b v1.6
git pull

hooopo
hooopo ^_^...
接近 5 年之前 回复
suannai0314
suannai0314 帮你编辑了下代码的格式,更详细的markdown使用方法见http://ask.csdn.net/pages/markdown
接近 5 年之前 回复
Csdn user default icon
上传中...
上传图片
插入图片
准确详细的回答,更有利于被提问者采纳,从而获得C币。复制、灌水、广告等回答会被删除,是时候展现真正的技术了!