dotfiles/duskwm/.config/dusk/status_scripts/scripts/clock.py

11 lines
323 B
Python

from datetime import datetime
from theme import current_theme, default
if current_theme.fg == current_theme.fg_alt:
current_theme.fg_alt = current_theme.base7
date = f"^c{current_theme.fg}^"
time = f"^c{current_theme.fg_alt}^"
data = datetime.now().strftime(f"{date}%a %b %d, {time}%H:%M")
content = f"^v^{data}^t^"