def out(app):
    app.check()
    if not os.path.exists(os.path.join(app.log_path(), 'system.out')):
        print "~ Oops! %s not found" % os.path.normpath(os.path.join(app.log_path(), 'system.out'))
        print "~"
        sys.exit(-1)
    sout = open(os.path.join(app.log_path(), 'system.out'), 'r')
    try:
        sout.seek(-5000, os.SEEK_END)
    except __HOLE__:
        sout.seek(0)
    while True:
        where = sout.tell()
        line = sout.readline().strip()
        if not line:
            time.sleep(1)
            sout.seek(where)
        else:
            print line
dataset/ETHPy150Open eBay/restcommander/play-1.2.4/framework/pym/play/commands/daemon.py/out