fix: store root path
Some checks failed
build / build (push) Has been cancelled

This commit is contained in:
张泊明518370910136 2025-02-27 01:14:40 -05:00
parent c4639aef76
commit 4c12bf9a34
GPG Key ID: D47306D7062CDA9D
2 changed files with 3 additions and 2 deletions

View File

@ -72,9 +72,9 @@ def convert(
)
task_obj = rtoml.loads(task_toml_path.read_text())
repo_conf = repo.Config(**repo_obj)
repo_conf.root = root
repo_conf.path = repo_toml_path.relative_to(root)
task_conf = task.Config(**task_obj)
task_conf.path = task_toml_path.relative_to(root)
result_model = convert_conf(repo_conf, task_conf)
result_dict = result_model.model_dump(by_alias=True, exclude_none=True)
with result_json_path.open("w") as result_file:

View File

@ -12,7 +12,8 @@ class Files(BaseModel):
class Config(BaseModel):
path: Path = Path(".")
root: Path = Path(".")
path: Path = Path("repo.toml")
teaching_team: List[str]
max_size: float = Field(..., ge=0)
release_tags: List[str]