1
0
mirror of synced 2026-01-07 00:01:39 -05:00

Merge pull request #23664 from github/repo-sync

repo sync
This commit is contained in:
Octomerger Bot
2023-02-02 11:32:45 -08:00
committed by GitHub
8 changed files with 37 additions and 37 deletions

View File

@@ -18,13 +18,13 @@ During an import, depending on the version control system you're importing from,
| Import action | Subversion | Mercurial | TFVC | Git |
|:--------------|:----------:|:---------:|:----------------------:|:---:|
| Authenticate with remote repository | **X** | **X** | **X** | **X** |
| [Update commit author attribution](/articles/updating-commit-author-attribution-with-github-importer) | **X** | **X** | **X** | |
| Move large files to [Git Large File Storage](/articles/about-git-large-file-storage) | **X** | **X** | **X** | |
| [Update commit author attribution](/get-started/importing-your-projects-to-github/importing-source-code-to-github/updating-commit-author-attribution-with-github-importer) | **X** | **X** | **X** | |
| Move large files to [Git Large File Storage](/repositories/working-with-files/managing-large-files/about-git-large-file-storage) | **X** | **X** | **X** | |
| Remove large files from your repository | **X** | **X** | **X** | |
## Further reading
- "[Importing a repository with GitHub Importer](/articles/importing-a-repository-with-github-importer)"
- "[Updating commit author attribution with GitHub Importer](/articles/updating-commit-author-attribution-with-github-importer)"
- "[Importing a Git repository using the command line](/articles/importing-a-git-repository-using-the-command-line)"
- "[Source code migration tools](/articles/source-code-migration-tools)"
- "[Importing a repository with GitHub Importer](/get-started/importing-your-projects-to-github/importing-source-code-to-github/importing-a-repository-with-github-importer)"
- "[Updating commit author attribution with GitHub Importer](/get-started/importing-your-projects-to-github/importing-source-code-to-github/updating-commit-author-attribution-with-github-importer)"
- "[Importing a Git repository using the command line](/get-started/importing-your-projects-to-github/importing-source-code-to-github/importing-a-git-repository-using-the-command-line)"
- "[Source code migration tools](/get-started/importing-your-projects-to-github/importing-source-code-to-github/source-code-migration-tools)"

View File

@@ -23,7 +23,7 @@ If you have existing source code or repositories stored locally on your computer
{% tip %}
**Tip:** If you're most comfortable with a point-and-click user interface, try adding your project with {% data variables.product.prodname_desktop %}. For more information, see "[Adding a repository from your local computer to GitHub Desktop](/desktop/guides/contributing-to-projects/adding-a-repository-from-your-local-computer-to-github-desktop)" in the *{% data variables.product.prodname_desktop %} Help*.
**Tip:** If you're most comfortable with a point-and-click user interface, try adding your project with {% data variables.product.prodname_desktop %}. For more information, see "[Adding a repository from your local computer to GitHub Desktop](/desktop/contributing-and-collaborating-using-github-desktop/adding-and-cloning-repositories/adding-a-repository-from-your-local-computer-to-github-desktop)" in the *{% data variables.product.prodname_desktop %} Help*.
{% endtip %}
@@ -84,14 +84,14 @@ If you have existing source code or repositories stored locally on your computer
```
7. At the top of your repository on {% ifversion ghae %}{% data variables.product.product_name %}{% else %}{% data variables.location.product_location %}{% endif %}'s Quick Setup page, click {% octicon "clippy" aria-label="The copy to clipboard icon" %} to copy the remote repository URL.
![Copy remote repository URL field](/assets/images/help/repository/copy-remote-repository-url-quick-setup.png)
8. In Terminal, [add the URL for the remote repository](/github/getting-started-with-github/managing-remote-repositories) where your local repository will be pushed.
8. In Terminal, [add the URL for the remote repository](/get-started/getting-started-with-git/managing-remote-repositories) where your local repository will be pushed.
```shell
$ git remote add origin <REMOTE_URL>
# Sets the new remote
$ git remote -v
# Verifies the new remote URL
```
9. [Push the changes](/github/getting-started-with-github/pushing-commits-to-a-remote-repository/) in your local repository to {% data variables.location.product_location %}.
9. [Push the changes](/get-started/using-git/pushing-commits-to-a-remote-repository) in your local repository to {% data variables.location.product_location %}.
```shell
$ git push -u origin main
# Pushes the changes in your local repository up to the remote repository you specified as the origin
@@ -101,7 +101,7 @@ If you have existing source code or repositories stored locally on your computer
{% windows %}
1. [Create a new repository](/articles/creating-a-new-repository) on {% data variables.location.product_location %}. To avoid errors, do not initialize the new repository with *README*, license, or `gitignore` files. You can add these files after your project has been pushed to {% data variables.product.product_name %}.
1. [Create a new repository](/repositories/creating-and-managing-repositories/creating-a-new-repository) on {% data variables.location.product_location %}. To avoid errors, do not initialize the new repository with *README*, license, or `gitignore` files. You can add these files after your project has been pushed to {% data variables.product.product_name %}.
![Create New Repository drop-down](/assets/images/help/repository/repo-create.png)
{% data reusables.command_line.open_the_multi_os_terminal %}
3. Change the current working directory to your local project.
@@ -130,14 +130,14 @@ If you have existing source code or repositories stored locally on your computer
```
7. At the top of your repository on {% ifversion ghae %}{% data variables.product.product_name %}{% else %}{% data variables.location.product_location %}{% endif %}'s Quick Setup page, click {% octicon "clippy" aria-label="The copy to clipboard icon" %} to copy the remote repository URL.
![Copy remote repository URL field](/assets/images/help/repository/copy-remote-repository-url-quick-setup.png)
8. In the Command prompt, [add the URL for the remote repository](/github/getting-started-with-github/managing-remote-repositories) where your local repository will be pushed.
8. In the Command prompt, [add the URL for the remote repository](/get-started/getting-started-with-git/managing-remote-repositories) where your local repository will be pushed.
```shell
$ git remote add origin <REMOTE_URL>
# Sets the new remote
$ git remote -v
# Verifies the new remote URL
```
9. [Push the changes](/github/getting-started-with-github/pushing-commits-to-a-remote-repository/) in your local repository to {% data variables.location.product_location %}.
9. [Push the changes](/get-started/using-git/pushing-commits-to-a-remote-repository) in your local repository to {% data variables.location.product_location %}.
```shell
$ git push origin main
# Pushes the changes in your local repository up to the remote repository you specified as the origin
@@ -147,7 +147,7 @@ If you have existing source code or repositories stored locally on your computer
{% linux %}
1. [Create a new repository](/articles/creating-a-new-repository) on {% data variables.location.product_location %}. To avoid errors, do not initialize the new repository with *README*, license, or `gitignore` files. You can add these files after your project has been pushed to {% data variables.product.product_name %}.
1. [Create a new repository](/repositories/creating-and-managing-repositories/creating-a-new-repository) on {% data variables.location.product_location %}. To avoid errors, do not initialize the new repository with *README*, license, or `gitignore` files. You can add these files after your project has been pushed to {% data variables.product.product_name %}.
![Create New Repository drop-down](/assets/images/help/repository/repo-create.png)
{% data reusables.command_line.open_the_multi_os_terminal %}
3. Change the current working directory to your local project.
@@ -176,14 +176,14 @@ If you have existing source code or repositories stored locally on your computer
```
7. At the top of your repository on {% ifversion ghae %}{% data variables.product.product_name %}{% else %}{% data variables.location.product_location %}{% endif %}'s Quick Setup page, click {% octicon "clippy" aria-label="The copy to clipboard icon" %} to copy the remote repository URL.
![Copy remote repository URL field](/assets/images/help/repository/copy-remote-repository-url-quick-setup.png)
8. In Terminal, [add the URL for the remote repository](/github/getting-started-with-github/managing-remote-repositories) where your local repository will be pushed.
8. In Terminal, [add the URL for the remote repository](/get-started/getting-started-with-git/managing-remote-repositories) where your local repository will be pushed.
```shell
$ git remote add origin <REMOTE_URL>
# Sets the new remote
$ git remote -v
# Verifies the new remote URL
```
9. [Push the changes](/github/getting-started-with-github/pushing-commits-to-a-remote-repository/) in your local repository to {% data variables.location.product_location %}.
9. [Push the changes](/get-started/using-git/pushing-commits-to-a-remote-repository) in your local repository to {% data variables.location.product_location %}.
```shell
$ git push origin main
# Pushes the changes in your local repository up to the remote repository you specified as the origin

View File

@@ -28,7 +28,7 @@ For purposes of demonstration, we'll use:
{% endtip %}
1. [Create a new repository on {% data variables.product.product_name %}](/articles/creating-a-new-repository). You'll import your external Git repository to this new repository.
1. [Create a new repository on {% data variables.product.product_name %}](/repositories/creating-and-managing-repositories/creating-a-new-repository). You'll import your external Git repository to this new repository.
2. On the command line, make a "bare" clone of the repository using the external clone URL. This creates a full copy of the data, but without a working directory for editing files, and ensures a clean, fresh export of all the old data.
```shell
$ git clone --bare https://external-host.com/EXTUSER/REPO.git

View File

@@ -13,7 +13,7 @@ shortTitle: Use GitHub Importer
---
{% tip %}
**Tip:** GitHub Importer is not suitable for all imports. For example, if your existing code is hosted on a private network, our tool won't be able to access it. In these cases, we recommend [importing using the command line](/articles/importing-a-git-repository-using-the-command-line) for Git repositories or an external [source code migration tool](/articles/source-code-migration-tools) for projects imported from other version control systems.
**Tip:** GitHub Importer is not suitable for all imports. For example, if your existing code is hosted on a private network, our tool won't be able to access it. In these cases, we recommend [importing using the command line](/get-started/importing-your-projects-to-github/importing-source-code-to-github/importing-a-git-repository-using-the-command-line) for Git repositories or an external [source code migration tool](/get-started/importing-your-projects-to-github/importing-source-code-to-github/source-code-migration-tools) for projects imported from other version control systems.
{% endtip %}
@@ -27,7 +27,7 @@ If you'd like to match the commits in your repository to the authors' GitHub per
![Text field for URL of imported repository](/assets/images/help/importer/import-url.png)
3. Choose your personal account or an organization to own the repository, then type a name for the repository on GitHub.
![Repository owner menu and repository name field](/assets/images/help/importer/import-repo-owner-name.png)
4. Specify whether the new repository should be *public* or *private*. For more information, see "[Setting repository visibility](/articles/setting-repository-visibility)."
4. Specify whether the new repository should be *public* or *private*. For more information, see "[Setting repository visibility](/repositories/managing-your-repositorys-settings-and-features/managing-repository-settings/setting-repository-visibility)."
![Public or private repository radio buttons](/assets/images/help/importer/import-public-or-private.png)
5. Review the information you entered, then click **Begin import**.
![Begin import button](/assets/images/help/importer/begin-import-button.png)
@@ -36,11 +36,11 @@ If SAML SSO or 2FA are enabled for your user account on the old project, enter a
![Password form and Submit button for password-protected project](/assets/images/help/importer/submit-old-credentials-importer.png)
7. If there are multiple projects hosted at your old project's clone URL, choose the project you'd like to import, then click **Submit**.
![List of projects to import and Submit button](/assets/images/help/importer/choose-project-importer.png)
8. If your project contains files larger than 100 MB, choose whether to import the large files using [Git Large File Storage](/articles/versioning-large-files), then click **Continue**.
8. If your project contains files larger than 100 MB, choose whether to import the large files using [Git Large File Storage](/repositories/working-with-files/managing-large-files), then click **Continue**.
![Git Large File Storage menu and Continue button](/assets/images/help/importer/select-gitlfs-importer.png)
You'll receive an email when the repository has been completely imported.
## Further reading
- "[Updating commit author attribution with GitHub Importer](/articles/updating-commit-author-attribution-with-github-importer)"
- "[Updating commit author attribution with GitHub Importer](/get-started/importing-your-projects-to-github/importing-source-code-to-github/updating-commit-author-attribution-with-github-importer)"

View File

@@ -15,7 +15,7 @@ shortTitle: Code migration tools
---
{% ifversion fpt or ghec %}
We recommend using [GitHub Importer](/articles/about-github-importer) to import projects from Subversion, Mercurial, Team Foundation Version Control (TFVC), or another Git repository. You can also use these external tools to convert your project to Git.
We recommend using [GitHub Importer](/get-started/importing-your-projects-to-github/importing-source-code-to-github/about-github-importer) to import projects from Subversion, Mercurial, Team Foundation Version Control (TFVC), or another Git repository. You can also use these external tools to convert your project to Git.
{% endif %}
@@ -43,7 +43,7 @@ For more information about moving from TFVC (a centralized version control syste
{% tip %}
**Tip:** After you've successfully converted your project to Git, you can [push it to {% data variables.product.prodname_dotcom %}](/github/getting-started-with-github/pushing-commits-to-a-remote-repository/).
**Tip:** After you've successfully converted your project to Git, you can [push it to {% data variables.product.prodname_dotcom %}](/get-started/using-git/pushing-commits-to-a-remote-repository).
{% endtip %}
@@ -51,8 +51,8 @@ For more information about moving from TFVC (a centralized version control syste
## Further reading
- "[About GitHub Importer](/articles/about-github-importer)"
- "[Importing a repository with GitHub Importer](/articles/importing-a-repository-with-github-importer)"
- "[About GitHub Importer](/get-started/importing-your-projects-to-github/importing-source-code-to-github/about-github-importer)"
- "[Importing a repository with GitHub Importer](/get-started/importing-your-projects-to-github/importing-source-code-to-github/importing-a-repository-with-github-importer)"
- [{% data variables.product.prodname_learning %}]({% data variables.product.prodname_learning_link %})
{% endif %}

View File

@@ -22,23 +22,23 @@ GitHub Importer looks for GitHub users whose email addresses match the authors o
## Attributing commits to a GitHub user with a public email address
If the author of a commit in your imported repository has a GitHub account associated with the email address they used to author the commits, and they haven't [set their commit email address as private](/articles/setting-your-commit-email-address), GitHub Importer will match the email address associated with the commit to the public email address associated with their GitHub account, and attribute the commit to their GitHub account.
If the author of a commit in your imported repository has a GitHub account associated with the email address they used to author the commits, and they haven't [set their commit email address as private](/account-and-profile/setting-up-and-managing-your-personal-account-on-github/managing-email-preferences/setting-your-commit-email-address), GitHub Importer will match the email address associated with the commit to the public email address associated with their GitHub account, and attribute the commit to their GitHub account.
## Attributing commits to a GitHub user without a public email address
If the author of a commit in your imported repository has neither set a public email address on their GitHub profile, nor [set their commit email address as private](/articles/setting-your-commit-email-address), GitHub Importer may not be able to match the email address associated with the commit with their GitHub account.
If the author of a commit in your imported repository has neither set a public email address on their GitHub profile, nor [set their commit email address as private](/account-and-profile/setting-up-and-managing-your-personal-account-on-github/managing-email-preferences/setting-your-commit-email-address), GitHub Importer may not be able to match the email address associated with the commit with their GitHub account.
The commit author can resolve this by setting their email address as private. Their commits will then be attributed to `<username>@users.noreply.github.com`, and the imported commits will be associated with their GitHub account.
## Attributing commits using an email address
If the author's email address is not associated with their GitHub account, they can [add the address to their account](/articles/adding-an-email-address-to-your-github-account) after the import, and the commits will be correctly attributed.
If the author's email address is not associated with their GitHub account, they can [add the address to their account](/account-and-profile/setting-up-and-managing-your-personal-account-on-github/managing-email-preferences/adding-an-email-address-to-your-github-account) after the import, and the commits will be correctly attributed.
If the author does not have a GitHub account, GitHub Importer will attribute their commits to the email address associated with the commits.
## Further reading
- "[About GitHub Importer](/articles/about-github-importer)"
- "[Importing a repository with GitHub Importer](/articles/importing-a-repository-with-github-importer)"
- "[Adding an email address to your account](/articles/adding-an-email-address-to-your-github-account/)"
- "[Setting your commit email address](/articles/setting-your-commit-email-address)"
- "[About GitHub Importer](/get-started/importing-your-projects-to-github/importing-source-code-to-github/about-github-importer)"
- "[Importing a repository with GitHub Importer](/get-started/importing-your-projects-to-github/importing-source-code-to-github/importing-a-repository-with-github-importer)"
- "[Adding an email address to your account](/account-and-profile/setting-up-and-managing-your-personal-account-on-github/managing-email-preferences/adding-an-email-address-to-your-github-account)"
- "[Setting your commit email address](/account-and-profile/setting-up-and-managing-your-personal-account-on-github/managing-email-preferences/setting-your-commit-email-address)"

View File

@@ -133,4 +133,4 @@ With this commit SHA, you can, for example, look up the corresponding Git commit
## Further reading
* "[Subversion properties supported by GitHub](/articles/subversion-properties-supported-by-github)"
* "[Subversion properties supported by GitHub](/get-started/importing-your-projects-to-github/working-with-subversion-on-github/subversion-properties-supported-by-github)"

View File

@@ -54,11 +54,11 @@ For more information, see "[Git Tools Submodules](https://git-scm.com/book/en/Gi
## Preserving history
SVN is configured to assume that the history of a project never changes. Git allows you to modify previous commits and changes using tools like [`git rebase`](/github/getting-started-with-github/about-git-rebase).
SVN is configured to assume that the history of a project never changes. Git allows you to modify previous commits and changes using tools like [`git rebase`](/get-started/using-git/about-git-rebase).
{% tip %}
[GitHub supports Subversion clients](/articles/support-for-subversion-clients), which may produce some unexpected results if you're using both Git and SVN on the same project. If you've manipulated Git's commit history, those same commits will always remain within SVN's history. If you accidentally committed some sensitive data, we have [an article that will help you remove it from Git's history](/articles/removing-sensitive-data-from-a-repository).
[GitHub supports Subversion clients](/get-started/importing-your-projects-to-github/working-with-subversion-on-github/support-for-subversion-clients), which may produce some unexpected results if you're using both Git and SVN on the same project. If you've manipulated Git's commit history, those same commits will always remain within SVN's history. If you accidentally committed some sensitive data, we have [an article that will help you remove it from Git's history](/authentication/keeping-your-account-and-data-secure/removing-sensitive-data-from-a-repository).
{% endtip %}
@@ -66,7 +66,7 @@ SVN is configured to assume that the history of a project never changes. Git all
## Further reading
- "[Subversion properties supported by GitHub](/articles/subversion-properties-supported-by-github)"
- "[Subversion properties supported by GitHub](/get-started/importing-your-projects-to-github/working-with-subversion-on-github/subversion-properties-supported-by-github)"
- ["Branching and Merging" from the _Git SCM_ book](https://git-scm.com/book/en/Git-Branching-Basic-Branching-and-Merging)
- "[Importing source code to GitHub](/articles/importing-source-code-to-github)"
- "[Source code migration tools](/articles/source-code-migration-tools)"
- "[Importing source code to GitHub](/get-started/importing-your-projects-to-github/importing-source-code-to-github)"
- "[Source code migration tools](/get-started/importing-your-projects-to-github/importing-source-code-to-github/source-code-migration-tools)"