#!/usr/bin/env python
# coding: utf-8

import thebot
import sys

from time import sleep
from contexlib import closing

def main():
    with closing(thebot.Bot(sys.argv[1:])) as bot:
        try:
            while not bot.exiting:
                sleep(1)
        except KeyboardInterrupt:
            pass


if __name__ == '__main__':
    main()

