InfoSphere/GitHub Desktop/ 返回书籍
Add & clone repositories

Clone a GitHub repo

qianmoQqianmoQ· 更新于 2026-09-16· 阅读 6 分钟· 0 次阅读

登录后可跨设备保存划线和私人笔记登录

Cloning a repository from GitHub to GitHub Desktop

You can use GitHub to clone remote repositories to GitHub Desktop.

[!TIP]
You also can use GitHub Desktop to clone repositories that exist on GitHub. For more information, see Cloning and forking repositories from GitHub Desktop.

  1. Sign in to GitHub and GitHub Desktop before you start to clone.

  2. On GitHub, navigate to the main page of the repository.

  3. Above the list of files, click Code.

    Screenshot of the list of files on the landing page of a repository. The "Code" button is highlighted with a dark orange outline.

  4. To clone and open the repository with GitHub Desktop, click Open with GitHub Desktop.

    Screenshot of the "Code" dropdown for a repository. A button, labeled "Open with GitHub Desktop" is outlined in dark orange.

  5. Click Choose... and navigate to a local directory where you want to clone the repository.

    Screenshot of the "URL" tab of the "Clone a Repository" window. Next to the "Local Path" field, a button, labeled "Choose", is outlined in orange.

    [!NOTE]
    If the repository is configured to use LFS, you will be prompted to initialize Git LFS.

  6. Click Clone.

评论

登录后参与评论

正在加载评论…