示例#1
0
class MainListBuffer(Buffer):
    display_name = "Listing"
    description = "List of all known docker images and containers display in a single list"
    keybinds = {
        "d": "rm",  # TODO: do also rmi
        "s": "start",
        "t": "stop",
        "r": "restart",
        "X": "kill",
        "p": "pause",
        "u": "unpause",
        "enter": "display-info",
        "b": "open-browser",
        "l": "logs",
        "f": "logs -f",
        "i": "inspect",
        "!": "toggle-live-updates",  # TODO: rfe: move to global so this affects every buffer
        "@": "refresh",  # FIXME: move to global and refactor & rewrite
    }

    def __init__(self, ui, docker_backend):
        self.ui = ui
        self.widget = MainListBox(ui, docker_backend)
        super().__init__()

    def process_realtime_event(self, event):
        self.widget.process_realtime_event(event)
示例#2
0
文件: buffer.py 项目: rm3l/sen
class MainListBuffer(Buffer):
    display_name = "Listing"
    description = "List of all known docker images and containers display in a single list"
    keybinds = {
        "d": "rm",  # TODO: do also rmi
        "s": "start",
        "t": "stop",
        "r": "restart",
        "X": "kill",
        "p": "pause",
        "u": "unpause",
        "enter": "display-info",
        "b": "open-browser",
        "l": "logs",
        "f": "logs -f",
        "i": "inspect",
        "!":
        "toggle-live-updates",  # TODO: rfe: move to global so this affects every buffer
        "@": "refresh",  # FIXME: move to global and refactor & rewrite
    }

    def __init__(self, ui, docker_backend):
        self.ui = ui
        self.widget = MainListBox(ui, docker_backend)
        super().__init__()

    def process_realtime_event(self, event):
        self.widget.process_realtime_event(event)
示例#3
0
 def __init__(self, ui, docker_backend):
     self.ui = ui
     self.widget = MainListBox(ui, docker_backend)
     super().__init__()
示例#4
0
文件: buffer.py 项目: rm3l/sen
 def __init__(self, ui, docker_backend):
     self.ui = ui
     self.widget = MainListBox(ui, docker_backend)
     super().__init__()