install libev on build scripts

+ fix: scanning system dirs on mac
This commit is contained in:
cwilvx
2025-04-03 14:25:44 +03:00
parent d6821bb6d3
commit 056c0456f9
7 changed files with 17 additions and 9 deletions
+10
View File
@@ -14,6 +14,16 @@ def run_fast_scandir(_dir: str, full=False) -> tuple[list[str], list[str]]:
Scans a directory for files with a specific extension.
Returns a list of files and folders in the directory.
"""
# if on mac, ignore Library folder and its children
if os.name == "posix":
dir_path = Path(_dir)
library_path = Path.home() / "Library"
if dir_path == library_path or library_path in dir_path.parents:
return [], []
# if the path contains "node_modules" ignore
if "node_modules" in _dir:
return [], []
if _dir == "":
return [], []