zipseq ignore _CURRENT
This commit is contained in:
@@ -122,13 +122,13 @@ def log(mode: str, message: str, *, verbose_only: bool = False, verbose: bool =
|
||||
|
||||
|
||||
def is_archive_path(path: Path) -> bool:
|
||||
return any(part == "_archive" for part in path.parts)
|
||||
return any(part in ("_archive", "_CURRENT") for part in path.parts)
|
||||
|
||||
|
||||
def find_sequence_dirs(root: Path) -> Iterator[Path]:
|
||||
for dirpath, dirnames, filenames in os.walk(root):
|
||||
path = Path(dirpath)
|
||||
dirnames[:] = [d for d in dirnames if d != "_archive"]
|
||||
dirnames[:] = [d for d in dirnames if d not in ("_archive", "_CURRENT")]
|
||||
if is_archive_path(path):
|
||||
continue
|
||||
has_frames = any(Path(dirpath, f).suffix.lower() in SEQUENCE_EXTENSIONS for f in filenames)
|
||||
@@ -139,7 +139,7 @@ def find_sequence_dirs(root: Path) -> Iterator[Path]:
|
||||
def iter_sequence_files(seq_dir: Path) -> Iterator[Path]:
|
||||
for dirpath, dirnames, filenames in os.walk(seq_dir):
|
||||
path = Path(dirpath)
|
||||
dirnames[:] = [d for d in dirnames if d != "_archive"]
|
||||
dirnames[:] = [d for d in dirnames if d not in ("_archive", "_CURRENT")]
|
||||
if is_archive_path(path):
|
||||
continue
|
||||
for filename in filenames:
|
||||
|
||||
Reference in New Issue
Block a user