cronet import: use folder.origin instead of git.origin

git.origin uses a bare repo which is not supported by gclient. There may
be ways to get this to work including the git-origin-checkout-hook, but
those are a) really slow and b) much more complex than just using a
folder.origin.

This change also adds support to the import script to configure the
origin folder (i.e. clone the repo and run gclient) before the copybara
script is invoked.

Test: run import script
Change-Id: I6289108271960c87583a059a553b0d0e7db8af68
diff --git a/Cronet/tools/import/copy.bara.sky b/Cronet/tools/import/copy.bara.sky
index 104de68..59e59e3 100644
--- a/Cronet/tools/import/copy.bara.sky
+++ b/Cronet/tools/import/copy.bara.sky
@@ -19,6 +19,7 @@
 
     # Exclude existing *OWNERS files
     "**/*OWNERS",
+    "**/.git/**",
 ]
 
 cronet_origin_files = glob(
@@ -94,11 +95,8 @@
 core.workflow(
     name = "import_cronet",
     authoring = authoring.overwrite("Cronet Mainline Eng <cronet-mainline-eng+copybara@google.com>"),
-    origin = git.origin(
-        url = "https://chromium.googlesource.com/chromium/src.git",
-        # Source ref is set by the invoking script.
-        ref = "overwritten-by-script",
-    ),
+    # Origin folder is specified via source_ref argument, see import_cronet.sh
+    origin = folder.origin(),
     origin_files = cronet_origin_files,
     destination = git.destination(
         # The destination URL is set by the invoking script.