summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGravatar Yuri Kunde Schlesner2014-07-19 17:16:05 -0300
committerGravatar Yuri Kunde Schlesner2014-07-19 17:16:05 -0300
commit78eb8ba844b5ccb23644274481e18370dd8428e3 (patch)
treec85fe001e3a76f99dc2a268728e6468ede861f67 /src
parentMerge pull request #30 from neobrain/bitfield_work (diff)
downloadyuzu-78eb8ba844b5ccb23644274481e18370dd8428e3.tar.gz
yuzu-78eb8ba844b5ccb23644274481e18370dd8428e3.tar.xz
yuzu-78eb8ba844b5ccb23644274481e18370dd8428e3.zip
[build] Search for the git binary in the default msysgit install dir
The Git for Windows installer doesn't add the Git binaries to the path by default. (Due to risk of conflicts with built-in windows commands.) Unless you have configured your system specially this causes the scm_rev_gen.js script to fail to find Git. Added more paths to the script so that it searches in the default msysgit installation directory, eliminating the need to set the PATH for most environments.
Diffstat (limited to 'src')
-rw-r--r--src/common/scm_rev_gen.js9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/common/scm_rev_gen.js b/src/common/scm_rev_gen.js
index 29c913b85..98313e376 100644
--- a/src/common/scm_rev_gen.js
+++ b/src/common/scm_rev_gen.js
@@ -6,8 +6,15 @@ var cmd_revision = " rev-parse HEAD";
6var cmd_describe = " describe --always --long --dirty"; 6var cmd_describe = " describe --always --long --dirty";
7var cmd_branch = " rev-parse --abbrev-ref HEAD"; 7var cmd_branch = " rev-parse --abbrev-ref HEAD";
8 8
9var git_search_paths = {
10 "git.cmd": 1,
11 "git": 1,
12 "C:\\Program Files (x86)\\Git\\bin\\git.exe": 1,
13 "C:\\Program Files\\Git\\bin\\git.exe": 1
14};
15
9function GetGitExe() { 16function GetGitExe() {
10 for (var gitexe in { "git.cmd": 1, "git": 1 }) { 17 for (var gitexe in git_search_paths) {
11 try { 18 try {
12 wshShell.Exec(gitexe); 19 wshShell.Exec(gitexe);
13 return gitexe; 20 return gitexe;