haarcuba / myconsole

custom IPython based console with custom prompts and banners

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

MYCONSOLE

MYCONSOLE simplifies IPython configuration so that you can easily create a customized console. Just do this:

import myconsole

BANNER =\
"""
***********************************************
*                                             *
*       Welcome to the MYCONSOLE DEMO         *
*                                             *
***********************************************
"""

def main():
    parser = argparse.ArgumentParser()
    parser.add_argument( '--in', dest = 'inPrompt', metavar = 'STRING', default = 'MyConsole' )
    parser.add_argument( '--out', dest = 'outPrompt', metavar = 'STRING', default = None )
    arguments = parser.parse_args()
    console = myconsole.create( BANNER, arguments.inPrompt, arguments.outPrompt, exitMessage = 'enjoy your shiny new console!' )
    console()

The result:

picture

About

custom IPython based console with custom prompts and banners


Languages

Language:Python 100.0%