blob: fe836fced7079af066a26802093d76b6d6e902b1 [file] [log] [blame] [view]
Jeff Gaston7c491f22019-09-23 13:16:13 -04001# Checking out Metalava
2
Louis Pullen-Freilich84625dc2022-08-04 13:40:46 +00003Metalava can be downloaded from the `metalava-main` manifest branch via `repo` as explained below
Jeff Gaston7c491f22019-09-23 13:16:13 -04004
Louis Pullen-Freilich84625dc2022-08-04 13:40:46 +00005## To check out `metalava-main` using `repo`:
Jeff Gaston7c491f22019-09-23 13:16:13 -040061. Install `repo` (Repo is a tool that makes it easier to download multiple Git repositories at once. For more information about Repo, see the [Repo Command Reference](https://source.android.com/setup/develop/repo))
7
8```bash
9mkdir ~/bin
10PATH=~/bin:$PATH
11curl https://storage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
12chmod a+x ~/bin/repo
13```
14
152. Configure Git with your real name and email address.
16
17```bash
18git config --global user.name "Your Name"
19git config --global user.email "you@example.com"
20```
21
223. Create a directory for your checkout (it can be any name)
23
24```bash
Louis Pullen-Freilich84625dc2022-08-04 13:40:46 +000025mkdir metalava-main
26cd metalava-main
Jeff Gaston7c491f22019-09-23 13:16:13 -040027```
28
294. Use `repo` command to initialize the repository.
30
31```bash
Louis Pullen-Freilich84625dc2022-08-04 13:40:46 +000032repo init -u https://android.googlesource.com/platform/manifest -b metalava-main
Jeff Gaston7c491f22019-09-23 13:16:13 -040033```
34
355. Now your repository is configured to pull only what you need for building and running Metalava. Download the code (this may take some time; the checkout is about 1.7G):
36
37```bash
38repo sync -j8 -c
39```
40## Checking out `aosp/master` instead:
41
42For anyone that is already working in the `aosp/master` branch, you can use that repo checkout instead. For small changes to metalava, this is not recommended - it is a very large checkout, with many dependencies not used by metalava.
43
44## Developing
45
46See also [README.md](README.md) for details about building and running Metalava after you have checked out the code.
47