]> git.lizzy.rs Git - rust.git/blob - src/tools/build-manifest/README.md
More build-manifest docs
[rust.git] / src / tools / build-manifest / README.md
1 # build-manifest
2
3 This tool generates the manifests uploaded to static.rust-lang.org and used by rustup.
4 You can see a full list of all manifests at <https://static.rust-lang.org/manifests.txt>.
5 This listing is updated by <https://github.com/rust-lang/generate-manifest-list> every 7 days.
6
7 This gets called by `promote-release` <https://github.com/rust-lang/promote-release> via `x.py dist hash-and-sign`.
8
9 ## Adding a new component
10
11 1. Add a new `Step` to `dist.rs`. This should usually be named after the filename of the uploaded tarball. See https://github.com/rust-lang/rust/pull/101799/files#diff-2c56335faa24486df09ba392d8900c57e2fac4633e1f7038469bcf9ed3feb871 for an example.
12     a. If appropriate, call `tarball.is_preview(true)` for the component.
13 2. Add a new `PkgType` to build-manifest. Fix all the compile errors as appropriate.
14
15 ## Testing changes locally
16
17 In order to test the changes locally you need to have a valid dist directory
18 available locally. If you don't want to build all the compiler, you can easily
19 create one from the nightly artifacts with:
20
21 ```sh
22 for component in rust rustc rust-std rust-docs cargo; do
23     wget -P build/dist https://static.rust-lang.org/dist/${component}-nightly-x86_64-unknown-linux-gnu.tar.gz
24 done
25 ```
26
27 Then, you can generate the manifest and all the packages from `build/dist` to
28 `build/manifest` with:
29
30 ```sh
31 mkdir -p build/manifest
32 cargo +nightly run --release -p build-manifest build/dist build/manifest 1970-01-01 http://example.com nightly
33 ```