From b7607a9113760ee28680d94efca4b8f45e0a1988 Mon Sep 17 00:00:00 2001 From: jyn Date: Wed, 19 Apr 2023 08:25:29 -0500 Subject: [PATCH] configure: Set `profile = user` by default --- src/bootstrap/bootstrap_test.py | 1 + src/bootstrap/configure.py | 2 ++ 2 files changed, 3 insertions(+) diff --git a/src/bootstrap/bootstrap_test.py b/src/bootstrap/bootstrap_test.py index 6717eb21012..26bd80a008f 100644 --- a/src/bootstrap/bootstrap_test.py +++ b/src/bootstrap/bootstrap_test.py @@ -97,6 +97,7 @@ class GenerateAndParseConfig(unittest.TestCase): def test_no_args(self): build = self.serialize_and_parse([]) self.assertEqual(build.get_toml("changelog-seen"), '2') + self.assertEqual(build.get_toml("profile"), 'user') self.assertIsNone(build.get_toml("llvm.download-ci-llvm")) def test_set_section(self): diff --git a/src/bootstrap/configure.py b/src/bootstrap/configure.py index 5937d5a8cdd..7cc952b5c56 100755 --- a/src/bootstrap/configure.py +++ b/src/bootstrap/configure.py @@ -417,6 +417,8 @@ def parse_example_config(known_args, config): # Avoid using quotes unless it's necessary. targets[target][0] = targets[target][0].replace("x86_64-unknown-linux-gnu", "'{}'".format(target) if "." in target else target) + if 'profile' not in config: + set('profile', 'user', config) configure_file(sections, top_level_keys, targets, config) return section_order, sections, targets