Поддержка тем
This commit is contained in:
Mikan
2025-12-08 17:21:41 +03:00
parent c262bffb41
commit 8da965234c
3 changed files with 46 additions and 3 deletions

View File

@@ -14,9 +14,10 @@ def convert(
output_dir: Path = typer.Option(..., "--output", "-o", help="Папка для результата"),
style_config: Path = typer.Option("resources/style_config.yaml", "--style", "-s", help="Файл стилей"),
template: Optional[Path] = typer.Option(None, "--template", "-t", help="Шаблон .dotx"),
theme: Optional[str] = typer.Option(None, "--theme", "-T", help="Название темы (gost, academic...)"),
verbose: bool = typer.Option(False, "--verbose", "-v", help="Включить отладочные сообщения"),
):
log_level = logging.DEBUG if verbose else logging.INFO
logging.basicConfig(level=log_level, format='%(levelname)s: %(message)s')
process_document(input_dir, output_dir, style_config, template)
process_document(input_dir, output_dir, style_config, template, theme)