forked from mttu-developers/konabot
14 lines
301 B
Python
14 lines
301 B
Python
from pathlib import Path
|
|
from watchfiles import Change
|
|
|
|
|
|
base = Path(__file__).parent.parent.absolute()
|
|
|
|
|
|
def filter(change: Change, path: str) -> bool:
|
|
if "__pycache__" in path:
|
|
return False
|
|
if Path(path).absolute().is_relative_to(base / "data"):
|
|
return False
|
|
return True
|