baseimage-tutorial-framework/lib/tfw/builtins/terminal_commands_event_handler.py

10 lines
235 B
Python
Raw Normal View History

from tfw.components import TerminalCommands
class TerminalCommandsEventHandler(TerminalCommands):
keys = ['history.bash']
def handle_event(self, message, _):
command = message['value']
self.callback(command)