当我试图在终端中拉入我的项目目录时,我看到以下错误:
harsukh@harsukh-desktop:~/Sites/branch1$ git pull origin master
U app/config/app.php
U app/config/database.php
U app/routes.php
Pull is not possible because you have unmerged files.
Please, fix them up in the work tree, and then use 'git add/rm <file>'
as appropriate to mark resolution, or use 'git commit -a'.
为什么git说“拉是不可能的,因为你有未合并的文件”,我该如何解决它?
我也有同样的问题
在我的案例中,步骤如下-
删除了所有以U(未合并)符号开始的文件。作为- - - - - -
U project/app/pages/file1/file.ts
U project/www/assets/file1/file-name.html
从master中提取代码
$ git pull origin master
检查状态
$ git status
这是它出现的消息
分别有2个和1个不同的提交。
(使用“git pull”将远程分支合并到您的分支中)
你有未合并的路径。
(修复冲突并运行“git commit”)
Unmerged路径:
(使用“git add…”来标记分辨率)
both modified: project/app/pages/file1/file.ts
both modified: project/www/assets/file1/file-name.html
增加了所有新的变化-
$ git add project/app/pages/file1/file.ts
project/www/assets/file1/file-name.html
在head上提交更改
$ git commit -am "resolved conflict of the app."
〇推送密码
$ git push origin master
用这个图像可以解决哪一个问题