gmyth-stream/server/0.3/gms.py
branchtrunk
changeset 720 365a09aee64b
child 723 f5f7abc760aa
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/gmyth-stream/server/0.3/gms.py	Wed May 30 14:46:18 2007 +0100
     1.3 @@ -0,0 +1,26 @@
     1.4 +#!/usr/bin/env python
     1.5 +
     1.6 +__author__ = "Artur Duque de Souza"
     1.7 +__author_email__ = "artur.souza@indt.org.br"
     1.8 +__license__ = "GPL"
     1.9 +__version__ = "0.3"
    1.10 +__thanks__ = "Gustavo Sverzut Barbieri"
    1.11 +
    1.12 +import sys
    1.13 +import os
    1.14 +import logging as log
    1.15 +from lib.server import serve_forever, load_plugins_transcoders
    1.16 +
    1.17 +log_level = log.INFO
    1.18 +for p in sys.argv[1:]:
    1.19 +    if p == "-v" or p == "--verbose":
    1.20 +        log_level -= 10
    1.21 +
    1.22 +log.basicConfig(level=log_level,
    1.23 +                format=("### %(asctime)s %(name)-18s \t%(levelname)-8s "
    1.24 +                        "\t%(message)s"),
    1.25 +                datefmt="%Y-%m-%d %H:%M:%S")
    1.26 +
    1.27 +pd = os.path.join("plugins", "transcoders")
    1.28 +load_plugins_transcoders(pd)
    1.29 +serve_forever()