I'm using Ubuntu 14.04 and i just followed each and every step in this link. After installing jdk, Git, creating working directory, i want to download Android 5.1 latest revision of source .
$ repo init -u https://android.googlesource.com/platform/manifest -b
what is the correct command to download 5.1. Can you tell me how much size of the source code is?
The instructions say do this
repo init -u https://android.googlesource.com/platform/manifest -b android-4.0.1_r1
But use the following link to replace android-4.0.1_r1
with the source version of your choice.
https://source.android.com/source/build-numbers.html#source-code-tags-and-builds
Since you want the latest 5.1, that would be android-5.1.1_r30
at the time of this post.
So, your command would be
ANDROID_TARGET=android-5.1.1_r30
repo init -u https://android.googlesource.com/platform/manifest -b $ANDROID_TARGET