fix(devgen): handle missing git binary gracefully

Ensure the function returns an empty list when git is not found, avoiding crashes.
This commit is contained in:
sankalp committed 2026-07-03 18:08:00 +05:45
1 parent 261d04c56f
commit d4b694e77d
1 file changed
+1 -1
+1 -1
View File
@@ -199,7 +199,7 @@ def get_git_staged_files() -> list[str]:
try:
output = run_git_command(["git", "diff", "--name-only", "--cached"])
return [f for f in output.splitlines() if f.strip()]
except subprocess.CalledProcessError:
except (subprocess.CalledProcessError, FileNotFoundError):
return []