diff options
author | Jason Wessel <jason.wessel@windriver.com> | 2012-09-17 17:43:49 -0500 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2012-09-24 15:35:32 +0100 |
commit | 98ac5e4e6230095487b819b911890ec64e28d5f7 (patch) | |
tree | c25e92de41ccdeca570fb3a7b744c0b3327f2c17 /bitbake/lib/bb/event.py | |
parent | eab93b0d625aba061a73b9c5f7ce7828495f1338 (diff) | |
download | poky-98ac5e4e6230095487b819b911890ec64e28d5f7.tar.gz |
bitbake: event.py, knotty.py, ncurses.py, runningbuild.py: Add support for LogExecTTY event
The LogExecTTY even is intended to provide the ability to spawn a task
on a the controlling tty, if a tty is availble. When a controlling
tty is not availble the previous behavior is preserved where a warning
is issued about the action an end user must execute.
All the available UI's were tested against the new event type.
This feature is primarily intended for hooking up a screen client
session automatically on the controlling tty to allow for a more
streamlined end user experience when using a pure command line driven
environment. The changes that send the LogExecTTY event are in the
oe-core side.
(Bitbake rev: cffe80d82a46aaf52ff4a7b6409435754043553f)
Signed-off-by: Jason Wessel <jason.wessel@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/bb/event.py')
-rw-r--r-- | bitbake/lib/bb/event.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/bitbake/lib/bb/event.py b/bitbake/lib/bb/event.py index 7ee28fcfcb..deb1c21595 100644 --- a/bitbake/lib/bb/event.py +++ b/bitbake/lib/bb/event.py | |||
@@ -510,6 +510,15 @@ class MsgFatal(MsgBase): | |||
510 | class MsgPlain(MsgBase): | 510 | class MsgPlain(MsgBase): |
511 | """General output""" | 511 | """General output""" |
512 | 512 | ||
513 | class LogExecTTY(Event): | ||
514 | """Send event containing program to spawn on tty of the logger""" | ||
515 | def __init__(self, msg, prog, sleep_delay, retries): | ||
516 | Event.__init__(self) | ||
517 | self.msg = msg | ||
518 | self.prog = prog | ||
519 | self.sleep_delay = sleep_delay | ||
520 | self.retries = retries | ||
521 | |||
513 | class LogHandler(logging.Handler): | 522 | class LogHandler(logging.Handler): |
514 | """Dispatch logging messages as bitbake events""" | 523 | """Dispatch logging messages as bitbake events""" |
515 | 524 | ||