diff options
| author | Matthias Krüger <matthias.krueger@famsik.de> | 2023-02-11 17:18:43 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-02-11 17:18:43 +0100 |
| commit | 420e756c8ad321c66d2a94307d8d3dd9dae0ddf2 (patch) | |
| tree | 61aa420996e6af1cc7d2b5292eb638f014cbcf2f | |
| parent | 240d5e0f6886f1741cb67bade8629b97e8396af7 (diff) | |
| parent | 1057e2132e32764676e89e88992dc7a4c3e955ea (diff) | |
| download | rust-420e756c8ad321c66d2a94307d8d3dd9dae0ddf2.tar.gz rust-420e756c8ad321c66d2a94307d8d3dd9dae0ddf2.zip | |
Rollup merge of #107873 - zephaniahong:issue-107832-fix, r=albertlarsan68
Emit JSON output for the building of bootstrap itself Fixes #107832 . Main changes are from line 792 onwards. Other changes are due to the flake8 formatter. Let me know if I should not use the formatter.
| -rw-r--r-- | src/bootstrap/bootstrap.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/bootstrap/bootstrap.py b/src/bootstrap/bootstrap.py index 45f238ef4bf..013d1ab525b 100644 --- a/src/bootstrap/bootstrap.py +++ b/src/bootstrap/bootstrap.py @@ -784,6 +784,8 @@ class RustBuild(object): if self.get_toml("metrics", "build"): args.append("--features") args.append("build-metrics") + if self.json_output: + args.append("--message-format=json") if color == "always": args.append("--color=always") elif color == "never": @@ -841,6 +843,7 @@ def parse_args(): parser.add_argument('--build') parser.add_argument('--color', choices=['always', 'never', 'auto']) parser.add_argument('--clean', action='store_true') + parser.add_argument('--json-output', action='store_true') parser.add_argument('-v', '--verbose', action='count', default=0) return parser.parse_known_args(sys.argv)[0] @@ -852,6 +855,7 @@ def bootstrap(args): build.rust_root = os.path.abspath(os.path.join(__file__, '../../..')) build.verbose = args.verbose != 0 build.clean = args.clean + build.json_output = args.json_output # Read from `--config`, then `RUST_BOOTSTRAP_CONFIG`, then `./config.toml`, # then `config.toml` in the root directory. |
