Repo is a tool that Google built on top of Git to manage the many Git repositories, do the uploads to revision control system, and automate parts of the Android development workflow. Repo is not meant to replace Git, rather to make it easier to work with Git in the context of Android. The repo command is an executable Python script that can be put anywhere in the development system. Repo is released under Apache License 2.0.
According to the Google OpenSource Blog the reason this tool was created was, with approximately 8.5 million lines of code (not including things like the Linux Kernel), keeping this all in one Git tree would've been problematic because these requirements would not have been met:
Delineate access control based on location in the tree.
Ability to make some components replaceable at a later date.
Trivial overlays for OEMs and other projects that do not embrace open source.
No need for technical people to spend their time as patch monkeys.
Git is an open source revision control system designed to handle projects that are distributed over multiple repositories. In the context of Android, Git is used for local operations such as local branching, commits, diffs, and edits. Repo is used for across-network operations. For example, with a single Repo command it is possible to download files from multiple repositories into your local working directory.
The google-repo-setup.sh shell script will automatically perform the operations described in the various command-line configuration and installation instructions, and will work with any of the package managers described therein.