summaryrefslogtreecommitdiff
path: root/bitbake-dev/lib/bb
diff options
context:
space:
mode:
Diffstat (limited to 'bitbake-dev/lib/bb')
-rw-r--r--bitbake-dev/lib/bb/command.py11
-rw-r--r--bitbake-dev/lib/bb/ui/knotty.py4
2 files changed, 12 insertions, 3 deletions
diff --git a/bitbake-dev/lib/bb/command.py b/bitbake-dev/lib/bb/command.py
index 7cee1d5d3..0d4ef4256 100644
--- a/bitbake-dev/lib/bb/command.py
+++ b/bitbake-dev/lib/bb/command.py
@@ -114,7 +114,7 @@ class CommandsSync:
"""
return command.cooker.commandlineAction
- def readVariable(self, command, params):
+ def getVariable(self, command, params):
"""
Read the value of a variable from configuration.data
"""
@@ -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
diff --git a/bitbake-dev/lib/bb/ui/knotty.py b/bitbake-dev/lib/bb/ui/knotty.py
index 5e7544ea0..4b4d6b03a 100644
--- a/bitbake-dev/lib/bb/ui/knotty.py
+++ b/bitbake-dev/lib/bb/ui/knotty.py
@@ -32,8 +32,8 @@ parsespin = itertools.cycle( r'|/-\\' )
def init(server, eventHandler):
# Get values of variables which control our output
- includelogs = server.runCommand(["readVariable", "BBINCLUDELOGS"])
- loglines = server.runCommand(["readVariable", "BBINCLUDELOGS_LINES"])
+ includelogs = server.runCommand(["getVariable", "BBINCLUDELOGS"])
+ loglines = server.runCommand(["getVariable", "BBINCLUDELOGS_LINES"])
try:
cmdline = server.runCommand(["getCmdLineAction"])