refact: rename bopytex to service

This commit is contained in:
2022-04-09 21:53:00 +02:00
parent 963348611a
commit e52b6eb064
3 changed files with 12 additions and 6 deletions

View File

@@ -4,9 +4,8 @@
import click
import logging
from pathlib import Path
from bopytex.bopytex import bopytex
from bopytex.service import bopytex
formatter = logging.Formatter("%(name)s :: %(levelname)s :: %(message)s")
steam_handler = logging.StreamHandler()
@@ -38,7 +37,11 @@ logger.addHandler(steam_handler)
help="CSV containing list of students names",
)
@click.option(
"-d", "--dirty", is_flag=True, default=False, help="Do not clean after compilation",
"-d",
"--dirty",
is_flag=True,
default=False,
help="Do not clean after compilation",
)
@click.option(
"-n",

View File

@@ -75,10 +75,12 @@ def bopytex(
)
tasks = planner(template, subjects, corr, no_join, no_pdf)
scheduler = Scheduler(actions, [template])
scheduler = Scheduler([template])
scheduler.append(tasks)
scheduler.run()
for _ in scheduler.backlog:
pass
# -----------------------------