From c344363fa3ad598c9b84dff280137624bbafe781 Mon Sep 17 00:00:00 2001 From: 苏向夜 Date: Tue, 23 Jan 2024 16:03:39 +0800 Subject: :sparkles: feat(api): new check command api --- src/ipm/api.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/ipm/api.py b/src/ipm/api.py index 7e0eda1..513eff9 100644 --- a/src/ipm/api.py +++ b/src/ipm/api.py @@ -18,6 +18,12 @@ import toml import shutil +def check(source_path: StrPath) -> None: + source_path = Path(source_path).resolve() + lock = ProjectLock(source_path) + lock.init() + + def init(source_path: StrPath, force: bool = False, echo: bool = False) -> None: source_path = Path(source_path).resolve() if (toml_path := (source_path / "infini.toml")).exists() and not force: -- cgit v1.2.3-70-g09d2