#! /usr/bin/python __author__="bjschuma" __date__ ="$Dec 18, 2009 12:08:57 AM$" global name, app, type, path, opt name = "cli" app = "scion" type = "core" path = "" opt = [] import curses from bt.message import write global maxxy, input, stdscr input = "" # Called every time the plugin is enabled def open(): write("Starting CLI", True) global maxxy, input, stdscr stdscr = curses.initscr() maxxy = stdscr.getmaxyx() curses.cbreak() curses.noecho() stdscr.keypad(1) # Called every time the plugin is stopped def close(): global stdscr curses.nocbreak() curses.echo() stdscr.keypad(0) curses.endwin() write("CLI has been stopped", True) # Called when the plugin needs to perform some action def run(): pass