aboutsummaryrefslogtreecommitdiffhomepage
path: root/libs/ffsubsync/__init__.py
blob: 3c40aeebaf8d354c446cb621ac6fda8523ff0a3d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
# -*- coding: utf-8 -*- 
import logging
import sys

try:
    from rich.console import Console
    from rich.logging import RichHandler

    # configure logging here because some other later imported library does it first otherwise
    # TODO: use a fileconfig
    logging.basicConfig(
        level=logging.INFO,
        format="%(message)s",
        datefmt="[%X]",
        handlers=[RichHandler(console=Console(file=sys.stderr))]
    )
except ImportError:
    logging.basicConfig(stream=sys.stderr, level=logging.INFO)

from .version import __version__  # noqa
from .ffsubsync import main  # noqa