mirror of
https://github.com/Garmelon/PFERD.git
synced 2025-09-09 14:12:26 +02:00
Add test run option to PFERD
This commit is contained in:
@@ -59,6 +59,8 @@ def _pattern(regex: Regex) -> re.Pattern:
|
||||
|
||||
# Transform combinators
|
||||
|
||||
keep = lambda path: path
|
||||
|
||||
def attempt(*args: Transform) -> Transform:
|
||||
def inner(path: PurePath) -> Optional[PurePath]:
|
||||
for transform in args:
|
||||
@@ -134,6 +136,7 @@ def re_rename(regex: Regex, target: str) -> Transform:
|
||||
return None
|
||||
return inner
|
||||
|
||||
|
||||
# def match(regex: Union[str, re.Pattern]) -> Transform:
|
||||
# pattern: re.Pattern
|
||||
# if isinstance(regex, str):
|
||||
|
Reference in New Issue
Block a user