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

Re: [PATCH] Fix git-push --mirror also mirroring refs/remotes/

From
Bryan Drewery <bryan@shatow.net>
Date
May 10, 2009, 20:50 UTC
Message-ID
<4A073E2E.6060403@shatow.net>
In-Reply-To
<200905102225.25508.markus.heidelberg@web.de>
My git is outdated on my development server, 1.5.6.5:
       --mirror
           Instead of naming each ref to push, specifies that all refs
under $GIT_DIR/refs/heads/ and $GIT_DIR/refs/tags/ be mirrored to the
remote repository. Newly created
           local refs will be pushed to the remote end, locally updated
refs will be force updated on the remote end, and deleted refs will be
removed from the remote end.
           This is the default if the configuration option
remote.<remote>.mirror is set.
So, it's a bug in the docs in 1.5.6.5.

This behavior makes no sense to me. Can we at least add a config option to make it not push remotes? I push my development repository to a remote private repository only as a backup, and push my master/next to a public repository. I see no reason to push my 8 remotes and all their branches to my backup repository.

Bryan
Markus Heidelberg wrote:
Show 22 quoted lines
> Bryan Drewery, 10.05.2009:
>   
>> git-push --mirror was incorrectly mirroring refs/remotes/
>>     
>
> No, that's correct.
>
>   
>> previously. This patch fixes it to follow the documentation
>> which is to mirror only refs/heads/ and refs/tags/.
>>     
>
> Where have you read this? In the git-push docs at the --mirror
> description there is written "all refs under $GIT_DIR/refs/".
>
> Markus
>
> --
> To unsubscribe from this list: send the line "unsubscribe git" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>   
Previous: Markus HeidelbergNext: Markus Heidelberg
Message 3 of 7 in “Fix git-push --mirror also mirroring refs/remotes/”
  1. Fix git-push --mirror also mirroring refs/remotes/Bryan Drewery, May 10, 2009
  2. Markus HeidelbergMay 10, 2009
  3. Bryan DreweryMay 10, 2009
  4. Markus HeidelbergMay 10, 2009
  5. Bryan DreweryMay 10, 2009
  6. Junio C HamanoMay 10, 2009
  7. Markus HeidelbergMay 10, 2009

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.