2011/12/23

那些年我們一起下載的巨大Android Source Code

我一直以為得下載repo、得有git、然後repo sync個半天一天才能擁有某一個release版本的source code...

$repo init -u git://android.git.kernel.org/platform/manifest -b "relaese-name"
$repo sync

blah blah blah blah
blah blah blah
blah blah
blah...

...
..
.

然後才能在Eclipse裡面去慢慢得trace~

但這世界一直在變,變化到沒有什麼是不變的!

上面的敘述也是...

請在你的Eclipse內安裝這個adt-addons,從此就不用再下載任何release,直接開始看code(讓我也沒理由藉口說要下載很久了...)

  1. Start Eclipse, go to Help -> Install New Software.
  2. Click Add...
  3. Enter http://goo.gl/uavEs into the Location field and whatever you want into the Name field. Press OK.
  4. Now Select the newly added repository from the dropdown in the Work with prompt. You should see Android Sources as the only available plugin:
thumb3
  1. Press Next, then Finish, wait, and restart Eclipse at the prompt.
  2. Voila - you're done. You should now be able to step into any Android class (this excludes native functions, however) and examine the source code. Do it during debugging or regular development and stop staring at boring class definitions.
  3. Code our next favorite app.
  4. ???
  5. Profit.


開始上工吧!



沒有留言: