repo_sync_manifest: Support --repo-url.

By default, repo makes network calls to its
remote git repository. This is a pain for
testing, so allow callers to specify a custom
URL (which can be a local file).

Change-Id: I694c4705e57df6ab1ab5da6093bb59d29cb29ef0
Reviewed-on: https://chromium-review.googlesource.com/1460272
Commit-Ready: Evan Hernandez <evanhernandez@chromium.org>
Tested-by: Evan Hernandez <evanhernandez@chromium.org>
Reviewed-by: Jason Clinton <jclinton@chromium.org>
diff --git a/scripts/repo_sync_manifest.py b/scripts/repo_sync_manifest.py
index a23447d..0197ad5 100644
--- a/scripts/repo_sync_manifest.py
+++ b/scripts/repo_sync_manifest.py
@@ -99,6 +99,8 @@
   optimization_group.add_argument(
       '--git-cache-dir', type='path',
       help='Git cache directory to use.')
+  optimization_group.add_argument(
+      '--repo-url', help='Repo repository location.')
 
   return parser
 
@@ -194,7 +196,8 @@
       manifest_repo_url=manifest_url,
       directory=options.repo_root,
       branch=options.branch,
-      git_cache_dir=options.git_cache_dir)
+      git_cache_dir=options.git_cache_dir,
+      repo_url=options.repo_url)
 
   if options.copy_repo:
     repo.PreLoad(options.copy_repo)