git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH v2 0/2] remote-hg: shared repo upgrade fix

From
Antoine Pelisse <apelisse@gmail.com>
Date
Aug 10, 2013, 15:18 UTC
Message-ID
<CALWbr2zKhvM_scRCER2GeBtRDF2=bvrDQWc+GZjDGExHeKRnQg@mail.gmail.com>
In-Reply-To
<1376087884-32060-1-git-send-email-felipe.contreras@gmail.com>

On Sat, Aug 10, 2013 at 12:38 AM, Felipe Contreras <felipe.contreras@gmail.com> wrote:

Show 19 quoted lines
> Hi,
>
> Same as before, except with commit messages updated, and improved the second
> patch:
>
> --- a/contrib/remote-helpers/git-remote-hg
> +++ b/contrib/remote-helpers/git-remote-hg
> @@ -400,8 +400,9 @@ def get_repo(url, alias):
>                  local_hg = os.path.join(shared_path, x, 'clone', '.hg')
>                  if not os.path.exists(local_hg):
>                      continue
> -                shutil.copytree(local_hg, hg_path)
> -                break
> +                if not os.path.exists(hg_path):
> +                    shutil.move(local_hg, hg_path)
> +                shutil.rmtree(os.path.join(shared_path, x, 'clone'))
>
>          # setup shared repo (if not there)
>          try:
FWIW,
Reviewed-by: Antoine Pelisse <apelisse@gmail.com>
Cheers,
Previous: Felipe Contreras
Message 4 of 4 in “remote-hg: shared repo upgrade fix”
  1. 0/2 remote-hg: shared repo upgrade fixFelipe Contreras, Aug 9, 2013
  2. 1/2 remote-hg: ensure shared repo is initializedFelipe Contreras, Aug 9, 2013
  3. 2/2 remote-hg: add shared repo upgradeFelipe Contreras, Aug 9, 2013
  4. Antoine PelisseAug 10, 2013

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.