feat: add task key sub_tag

This commit is contained in:
2026-08-28 15:44:46 +03:00
parent a77a430d51
commit 5401f04485
10 changed files with 136 additions and 80 deletions
+4 -4
View File
@@ -14,11 +14,11 @@ class EntryResolver:
self._ignore = ignore
self._max_depth = max_depth
def _resolve(self, basepath: Path, depth: int = 0) -> Iterable[Entry]:
def _resolve(self, rootpath: Path, basepath: Path, depth: int = 0) -> Iterable[Entry]:
if basepath.is_dir():
if basepath.name.startswith(".") or self._ignore.match_file(basepath):
return
entry = self._detector.detect_entry(basepath)
entry = self._detector.detect_entry(basepath, rootpath)
if entry:
yield entry
if (
@@ -27,7 +27,7 @@ class EntryResolver:
and basepath.is_dir()
):
for path in basepath.iterdir():
yield from self._resolve(path, depth + 1)
yield from self._resolve(rootpath, path, depth + 1)
def resolve(self, basepath: Path) -> Iterable[Entry]:
return self._resolve(basepath)
return self._resolve(basepath, basepath)