From efbe129d617d3819b9ef09711e0f1419646ce0c3 Mon Sep 17 00:00:00 2001 From: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com> Date: Mon, 17 May 2021 06:27:30 +1000 Subject: [PATCH] Add error for git not found in git_helper (#4011) * Add error for git not found in git_helper * Exc instead --- BuildChecker/git_helper.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/BuildChecker/git_helper.py b/BuildChecker/git_helper.py index 00fd93a43d..a2a6dfe6fd 100644 --- a/BuildChecker/git_helper.py +++ b/BuildChecker/git_helper.py @@ -45,6 +45,9 @@ def update_submodules(): if os.path.isfile("DISABLE_SUBMODULE_AUTOUPDATE"): return + if shutil.which("git") is None: + raise FileNotFoundError("git not found in PATH") + # If the status doesn't match, force VS to reload the solution. # status = run_command(["git", "submodule", "status"], capture=True) run_command(["git", "submodule", "update", "--init", "--recursive"])