-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathVR.py
More file actions
24 lines (15 loc) · 674 Bytes
/
VR.py
File metadata and controls
24 lines (15 loc) · 674 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
from imports import *
def _cli(paths: list[Path]):
n = len(paths)
if (n == 1) and (path := paths[0]).is_dir():
doStdSoloVideoCheck(paths[0])
elif (n == 1) and (path := paths[0]).is_file() and VR_OUT_FILENAME_REGEX.match(path.name):
cmpComplexlyPairedVideos(paths[0])
elif n == 2 and paths[0].is_dir() and paths[1].is_dir():
findVideoMatchingBetweenDir(paths[0], paths[1])
elif n and (n % 2 == 0) and all((p.is_file() and p.suffix.endswith(VX_MAIN_EXTS)) for p in paths):
cmpSimplyPairedVideos(paths)
else:
printUsage(VR_USAGE_0, paths)
if __name__ == '__main__':
wrapTrackBack(_cli, sys.argv[1:])