Add deploy.py: multi-device build/flash/provision with JSON config. Add espmon/: real-time ESP32 fleet monitoring daemon. Remove tools/flasher/ and tools/provisioning/ (superseded).
23 lines
469 B
Python
23 lines
469 B
Python
"""Terminal color helpers (same style as deploy.py)."""
|
|
|
|
|
|
class C:
|
|
RST = "\033[0m"
|
|
B = "\033[1m"
|
|
DIM = "\033[2m"
|
|
RED = "\033[91m"
|
|
GRN = "\033[92m"
|
|
YLW = "\033[93m"
|
|
BLU = "\033[94m"
|
|
CYN = "\033[96m"
|
|
|
|
|
|
def _tag(color: str, tag: str, msg: str):
|
|
print(f" {color}{C.B}[{tag}]{C.RST} {msg}")
|
|
|
|
|
|
def ok(m): _tag(C.GRN, " OK ", m)
|
|
def info(m): _tag(C.BLU, " .. ", m)
|
|
def warn(m): _tag(C.YLW, " !! ", m)
|
|
def err(m): _tag(C.RED, " XX ", m)
|