From fbfc669583328a6df2415ecc6343bba509e44459 Mon Sep 17 00:00:00 2001 From: Rob Bradford Date: Fri, 24 Oct 2008 14:44:30 +0100 Subject: bitbake-dev: add a setVariable command This is synonymous with the getVariable command and allows you to set values in the data dictionary. --- bitbake-dev/lib/bb/command.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/bitbake-dev/lib/bb/command.py b/bitbake-dev/lib/bb/command.py index 293202be54..0d4ef42569 100644 --- a/bitbake-dev/lib/bb/command.py +++ b/bitbake-dev/lib/bb/command.py @@ -125,6 +125,15 @@ class CommandsSync: return bb.data.getVar(varname, command.cooker.configuration.data, expand) + def setVariable(self, command, params): + """ + Set the value of variable in configuration.data + """ + varname = params[0] + value = params[1] + bb.data.setVar(varname, value, command.cooker.configuration.data) + + class CommandsAsync: """ A class of asynchronous commands -- cgit v1.2.3