From 7bf888e4740311d542724fea65288c60c3f9286e Mon Sep 17 00:00:00 2001 From: Jacques Lalancette Date: Sun, 31 Oct 2021 22:57:41 +0900 Subject: [PATCH] Make the last step a step in Mirroring a repo sect To make it more clear that the final push is required, it might be better to number that step as well. Combined with the extra? line break between the terminal commands in step 3 and "As with a bare clone..." it was confusing at first glance. --- .../duplicating-a-repository.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/content/repositories/creating-and-managing-repositories/duplicating-a-repository.md b/content/repositories/creating-and-managing-repositories/duplicating-a-repository.md index efe3ce49c6..fe81a4601c 100644 --- a/content/repositories/creating-and-managing-repositories/duplicating-a-repository.md +++ b/content/repositories/creating-and-managing-repositories/duplicating-a-repository.md @@ -87,13 +87,13 @@ If you want to mirror a repository in another location, including getting update $ cd repository-to-mirror $ git remote set-url --push origin https://{% data variables.command_line.codeblock %}/exampleuser/mirrored ``` +As with a bare clone, a mirrored clone includes all remote branches and tags, but all local references will be overwritten each time you fetch, so it will always be the same as the original repository. Setting the URL for pushes simplifies pushing to your mirror. -As with a bare clone, a mirrored clone includes all remote branches and tags, but all local references will be overwritten each time you fetch, so it will always be the same as the original repository. Setting the URL for pushes simplifies pushing to your mirror. To update your mirror, fetch updates and push. - -```shell -$ git fetch -p origin -$ git push --mirror -``` +4. To update your mirror, fetch updates and push. + ```shell + $ git fetch -p origin + $ git push --mirror + ``` {% ifversion fpt or ghec %} ## Further reading