3.1 Remotes and Clone
A local repository exists only on your computer. A remote repository is usually hosted on GitHub, GitLab, Gitee, or an internal company platform for backup, collaboration, and code review.
What does clone do?
bash
git clone https://github.com/example/project.gitgit clone downloads the remote history and files, then automatically names that remote URL origin.
Loading concept check...
You can inspect remote URLs:
bash
git remote -vThe output may look like:
text
origin https://github.com/example/project.git (fetch)
origin https://github.com/example/project.git (push)remote is a name, not the website itself
origin is only an alias. Think of it as "the default remote repository." The real address is the URL after it.
Note
After cloning, you have a local repository copy. When you commit locally, the remote repository does not update automatically; you need push.