repo

curl https://storage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
chmod a+x ~/bin/repo

https://source.android.com/source/downloading

mkdir new-proj
cd new-proj
repo init -u [upstream-url] [options]
repo sync
repo status

https://source.android.com/source/using-repo