gmyth-stream/server/0.2/gms.py
author melunko
Thu Apr 19 21:22:26 2007 +0100 (2007-04-19)
branchtrunk
changeset 576 6ee1dc7357e8
child 577 7dc357cbaa40
permissions -rw-r--r--
[svn r581] added GMYTH_USE_DEBUG test at gmyth_program_info_print() and gmyth_channel_info_print()
     1 #!/usr/bin/env python
     2 
     3 import sys
     4 import os
     5 import logging as log
     6 from lib.server import serve_forever, load_plugins_transcoders
     7 
     8 log_level = log.INFO
     9 for p in sys.argv[1:]:
    10     if p == "-v" or p == "--verbose":
    11         log_level -= 10
    12 
    13 log.basicConfig(level=log_level,
    14                 format=("### %(asctime)s %(name)-18s %(levelname)-8s "
    15                         "\t%(message)s"),
    16                 datefmt="%Y-%m-%d %H:%M:%S")
    17 
    18 pd = os.path.join("plugins", "transcoders")
    19 load_plugins_transcoders(pd)
    20 serve_forever()