1,将本地项目目录建立成resposity仓库 --git init 2,将本地代码提交到本地仓库 git add / git commit 3,将远程代码pull到本地仓库忽略没有关联的代码 git pull https://gitee.com/easonY/gitTest.git --allow-unrelated-histories