# Path: il2fb/ds/airbridge/typing.py



import io
import logging
import math
import sys
import threading
    import readline
    import pyreadline as readline
from colorama import init as init_colors, Fore, Style
from il2fb.ds.airbridge.typing import StringHandler, StringOrNone

try:
except ImportError:




LOG = logging.getLogger(__name__)

EXIT_COMMAND = 'exit'


def colorize_prompt(s: str) -> str:
    return f"{Fore.GREEN}{s}{Style.RESET_ALL}"


def colorize_error(s: str) -> str:
    return f"{Fore.RED}{s}{Style.RESET_ALL}"


def write_string_to_stream(stream: io.RawIOBase, s: str) -> None:
    stream.write(s)
    stream.flush()


def write_string_to_stdout(s: str) -> None:
    write_string_to_stream(sys.stdout, s)


def write_string_to_stderr(s: str) -> None:

# Path: il2fb/ds/airbridge/typing.py



# Path: il2fb/ds/airbridge/terminal.py
import io
import logging
import math
import sys
import threading
    import readline
    import pyreadline as readline
from colorama import init as init_colors, Fore, Style
from il2fb.ds.airbridge.typing import StringHandler, StringOrNone


try:
except ImportError:




LOG = logging.getLogger(__name__)

EXIT_COMMAND = 'exit'


def colorize_prompt(s: str) -> str:
    return f"{Fore.GREEN}{s}{Style.RESET_ALL}"


def colorize_error(s: str) -> str:
    return f"{Fore.RED}{s}{Style.RESET_ALL}"


def write_string_to_stream(stream: io.RawIOBase, s: str) -> None:
    stream.write(s)
    stream.flush()


def write_string_to_stdout(s: str) -> None:
    write_string_to_stream(sys.stdout, s)


def write_string_to_stderr(s: str) -> None:

    write_string_to_stream(sys.stderr, s)