public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [edk2-staging/EdkRepo] [PATCH v1] EdkRepo: Removing checkout in clone command
@ 2020-10-14 21:03 Bjorge, Erik C
  2020-10-14 21:09 ` Nate DeSimone
  2020-10-29 21:50 ` Nate DeSimone
  0 siblings, 2 replies; 3+ messages in thread
From: Bjorge, Erik C @ 2020-10-14 21:03 UTC (permalink / raw)
  To: devel
  Cc: Ashley E Desimone, Nate DeSimone, Puja Pandya, Bret Barkelew,
	Prince Agyeman

When cloning a repo the files do not need to be checked out.  This is
because files will be checked out based on information in the manifest
later.  This reduces a number of file operations on larger repos and
will improve clone performance.

Cc: Ashley E Desimone <ashley.e.desimone@intel.com>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
Cc: Puja Pandya <puja.pandya@intel.com>
Cc: Bret Barkelew <Bret.Barkelew@microsoft.com>
Cc: Prince Agyeman <prince.agyeman@intel.com>
Cc: Erik Bjorge <erik.c.bjorge@intel.com>
Signed-off-by: Erik Bjorge <erik.c.bjorge@intel.com>
---
 edkrepo/common/common_repo_functions.py | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/edkrepo/common/common_repo_functions.py b/edkrepo/common/common_repo_functions.py
index d14f89a..0d54bbf 100644
--- a/edkrepo/common/common_repo_functions.py
+++ b/edkrepo/common/common_repo_functions.py
@@ -79,9 +79,9 @@ def clone_repos(args, workspace_dir, repos_to_clone, project_client_side_hooks,
     for repo_to_clone in repos_to_clone:
         local_repo_path = os.path.join(workspace_dir, repo_to_clone.root)
         local_repo_url = repo_to_clone.remote_url
-        print ("Cloning from: " + str(local_repo_url))
-        repo = Repo.clone_from(local_repo_url, local_repo_path, progress=GitProgressHandler())
-        #Fetch notes
+        print("Cloning from: " + str(local_repo_url))
+        repo = Repo.clone_from(local_repo_url, local_repo_path, progress=GitProgressHandler(), no_checkout=True)
+        # Fetch notes
         repo.remotes.origin.fetch("refs/notes/*:refs/notes/*")
 
         # Add the primary remote so that a reference to the latest code is available when
-- 
2.21.0.windows.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [edk2-staging/EdkRepo] [PATCH v1] EdkRepo: Removing checkout in clone command
  2020-10-14 21:03 [edk2-staging/EdkRepo] [PATCH v1] EdkRepo: Removing checkout in clone command Bjorge, Erik C
@ 2020-10-14 21:09 ` Nate DeSimone
  2020-10-29 21:50 ` Nate DeSimone
  1 sibling, 0 replies; 3+ messages in thread
From: Nate DeSimone @ 2020-10-14 21:09 UTC (permalink / raw)
  To: Bjorge, Erik C, devel@edk2.groups.io
  Cc: Desimone, Ashley E, Pandya, Puja, Bret Barkelew, Agyeman, Prince

Reviewed-by: Nate DeSimone <nathaniel.l.desimone@intel.com>

> -----Original Message-----
> From: Erik Bjorge <erik.c.bjorge@intel.com>
> Sent: Wednesday, October 14, 2020 2:04 PM
> To: devel@edk2.groups.io
> Cc: Desimone, Ashley E <ashley.e.desimone@intel.com>; Desimone,
> Nathaniel L <nathaniel.l.desimone@intel.com>; Pandya, Puja
> <puja.pandya@intel.com>; Bret Barkelew <Bret.Barkelew@microsoft.com>;
> Agyeman, Prince <prince.agyeman@intel.com>
> Subject: [edk2-staging/EdkRepo] [PATCH v1] EdkRepo: Removing checkout in
> clone command
> 
> When cloning a repo the files do not need to be checked out.  This is because
> files will be checked out based on information in the manifest later.  This
> reduces a number of file operations on larger repos and will improve clone
> performance.
> 
> Cc: Ashley E Desimone <ashley.e.desimone@intel.com>
> Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
> Cc: Puja Pandya <puja.pandya@intel.com>
> Cc: Bret Barkelew <Bret.Barkelew@microsoft.com>
> Cc: Prince Agyeman <prince.agyeman@intel.com>
> Cc: Erik Bjorge <erik.c.bjorge@intel.com>
> Signed-off-by: Erik Bjorge <erik.c.bjorge@intel.com>
> ---
>  edkrepo/common/common_repo_functions.py | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/edkrepo/common/common_repo_functions.py
> b/edkrepo/common/common_repo_functions.py
> index d14f89a..0d54bbf 100644
> --- a/edkrepo/common/common_repo_functions.py
> +++ b/edkrepo/common/common_repo_functions.py
> @@ -79,9 +79,9 @@ def clone_repos(args, workspace_dir, repos_to_clone,
> project_client_side_hooks,
>      for repo_to_clone in repos_to_clone:
>          local_repo_path = os.path.join(workspace_dir, repo_to_clone.root)
>          local_repo_url = repo_to_clone.remote_url
> -        print ("Cloning from: " + str(local_repo_url))
> -        repo = Repo.clone_from(local_repo_url, local_repo_path,
> progress=GitProgressHandler())
> -        #Fetch notes
> +        print("Cloning from: " + str(local_repo_url))
> +        repo = Repo.clone_from(local_repo_url, local_repo_path,
> progress=GitProgressHandler(), no_checkout=True)
> +        # Fetch notes
>          repo.remotes.origin.fetch("refs/notes/*:refs/notes/*")
> 
>          # Add the primary remote so that a reference to the latest code is
> available when
> --
> 2.21.0.windows.1


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [edk2-staging/EdkRepo] [PATCH v1] EdkRepo: Removing checkout in clone command
  2020-10-14 21:03 [edk2-staging/EdkRepo] [PATCH v1] EdkRepo: Removing checkout in clone command Bjorge, Erik C
  2020-10-14 21:09 ` Nate DeSimone
@ 2020-10-29 21:50 ` Nate DeSimone
  1 sibling, 0 replies; 3+ messages in thread
From: Nate DeSimone @ 2020-10-29 21:50 UTC (permalink / raw)
  To: Bjorge, Erik C, devel@edk2.groups.io
  Cc: Desimone, Ashley E, Pandya, Puja, Bret Barkelew, Agyeman, Prince

Pushed: https://github.com/tianocore/edk2-staging/commit/05ec1a6

> -----Original Message-----
> From: Erik Bjorge <erik.c.bjorge@intel.com>
> Sent: Wednesday, October 14, 2020 2:04 PM
> To: devel@edk2.groups.io
> Cc: Desimone, Ashley E <ashley.e.desimone@intel.com>; Desimone,
> Nathaniel L <nathaniel.l.desimone@intel.com>; Pandya, Puja
> <puja.pandya@intel.com>; Bret Barkelew <Bret.Barkelew@microsoft.com>;
> Agyeman, Prince <prince.agyeman@intel.com>
> Subject: [edk2-staging/EdkRepo] [PATCH v1] EdkRepo: Removing checkout in
> clone command
> 
> When cloning a repo the files do not need to be checked out.  This is because
> files will be checked out based on information in the manifest later.  This
> reduces a number of file operations on larger repos and will improve clone
> performance.
> 
> Cc: Ashley E Desimone <ashley.e.desimone@intel.com>
> Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
> Cc: Puja Pandya <puja.pandya@intel.com>
> Cc: Bret Barkelew <Bret.Barkelew@microsoft.com>
> Cc: Prince Agyeman <prince.agyeman@intel.com>
> Cc: Erik Bjorge <erik.c.bjorge@intel.com>
> Signed-off-by: Erik Bjorge <erik.c.bjorge@intel.com>
> ---
>  edkrepo/common/common_repo_functions.py | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/edkrepo/common/common_repo_functions.py
> b/edkrepo/common/common_repo_functions.py
> index d14f89a..0d54bbf 100644
> --- a/edkrepo/common/common_repo_functions.py
> +++ b/edkrepo/common/common_repo_functions.py
> @@ -79,9 +79,9 @@ def clone_repos(args, workspace_dir, repos_to_clone,
> project_client_side_hooks,
>      for repo_to_clone in repos_to_clone:
>          local_repo_path = os.path.join(workspace_dir, repo_to_clone.root)
>          local_repo_url = repo_to_clone.remote_url
> -        print ("Cloning from: " + str(local_repo_url))
> -        repo = Repo.clone_from(local_repo_url, local_repo_path,
> progress=GitProgressHandler())
> -        #Fetch notes
> +        print("Cloning from: " + str(local_repo_url))
> +        repo = Repo.clone_from(local_repo_url, local_repo_path,
> progress=GitProgressHandler(), no_checkout=True)
> +        # Fetch notes
>          repo.remotes.origin.fetch("refs/notes/*:refs/notes/*")
> 
>          # Add the primary remote so that a reference to the latest code is
> available when
> --
> 2.21.0.windows.1


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-10-29 21:50 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-10-14 21:03 [edk2-staging/EdkRepo] [PATCH v1] EdkRepo: Removing checkout in clone command Bjorge, Erik C
2020-10-14 21:09 ` Nate DeSimone
2020-10-29 21:50 ` Nate DeSimone

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox