Change diff command used by manage_projects.py.
manage_projects.py was running `git diff-index --quiet HEAD --`
previously to check if project.config had changed. This apparently
returns an exit code of 1 in some cases where a diff was not expected.
Switch to using `git diff --quiet HEAD` to check if any differences are
found. This appears to be more reliable in some manual testing.
Change-Id: I253423e41f80d71a5f2389bfc421e799f00f6fd9
Reviewed-on: https://review.openstack.org/16236
Reviewed-by: James E. Blair <corvus@inaugust.com>
Reviewed-by: Paul Belanger <paul.belanger@polybeacon.com>
Approved: Monty Taylor <mordred@inaugust.com>
Reviewed-by: Monty Taylor <mordred@inaugust.com>
Tested-by: Jenkins
diff --git a/manage_projects.py b/manage_projects.py
index 0bb0fc7..9f5c518 100755
--- a/manage_projects.py
+++ b/manage_projects.py
@@ -113,7 +113,7 @@
status, _ = run_command("cp %s %s" %
(acl_config, acl_dest), status=True)
if status == 0:
- status = git_command(repo_path, "diff-index --quiet HEAD --")
+ status = git_command(repo_path, "diff --quiet HEAD")
if status != 0:
return True
return False