FrameForge/frame_forge/cli_utils.py
jlw4049 1f329677f7 feat: v1.1.0
feat: added support for specific frames being passed via the --frames arg. This should be a single string separated by : like so "1001:1002"
2024-03-01 16:29:47 -05:00

8 lines
223 B
Python

import re
def frame_list(frames: str) -> list:
if not re.match(r"\d+(?::\d+)*$", frames):
raise ValueError("Input must be in the format of int:int i.e. 101:104")
return [int(x) for x in frames.split(":")]