From patchwork Fri Jul 6 10:43:57 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [sumo, 6/8] toaster/checksettings: allow CUSTOM_XML_ONLY setting through env From: "Belal, Awais" X-Patchwork-Id: 152384 Message-Id: <1530873839-4445-6-git-send-email-awais_belal@mentor.com> To: Date: Fri, 6 Jul 2018 15:43:57 +0500 This change allows the CUSTOM_XML_ONLY toaster setting to be provided through the environment so the user can do this without mingling with the settings.xml in scenarios where modifying settings.xml is not achieveable. Signed-off-by: Awais Belal --- bitbake/lib/toaster/bldcontrol/management/commands/checksettings.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bitbake/lib/toaster/bldcontrol/management/commands/checksettings.py b/bitbake/lib/toaster/bldcontrol/management/commands/checksettings.py index 823c6f1..14298d9 100644 --- a/bitbake/lib/toaster/bldcontrol/management/commands/checksettings.py +++ b/bitbake/lib/toaster/bldcontrol/management/commands/checksettings.py @@ -74,8 +74,9 @@ class Command(BaseCommand): print("Loading default settings") call_command("loaddata", "settings") template_conf = os.environ.get("TEMPLATECONF", "") + custom_xml_only = os.environ.get("CUSTOM_XML_ONLY") - if ToasterSetting.objects.filter(name='CUSTOM_XML_ONLY').count() > 0: + if ToasterSetting.objects.filter(name='CUSTOM_XML_ONLY').count() > 0 or (not custom_xml_only == None): # only use the custom settings pass elif "poky" in template_conf: