Git 中 pull 和 clone 的区别

git pull
git clone

clone 是本地没有 repository 时,将远程 repository 整个下载过来。

pull 是本地有 repository 时,将远程 repository 里新的 commit 数据(如有的话)下载过来,并且与本地代码merge。

note:git pull相当于git fetch和git merge。

其意思是先从远程下载git项目里的文件,然后将文件与本地的分支进行merge。