git Status Shows Same File Twice - But with different path slash styles

限于喜欢 提交于 2019-12-25 04:19:21

问题


When I do a git status, I see a change list that looks like this:

#       modified:   CustomizablePDFs/InvoiceAdapter.php
#       deleted:    "CustomizablePDFs\\Model/AlignContainer.php"

If I add then commit CustomizablePDFs/InvoiceAdapter.php, it will be commited (as it should be) and no longer appear in the status list (good).

However, git status will still show deleted: "CustomizablePDFs\\Model/AlignContainer.php" on the status list. If I do a git rm using that file path, it fails saying that the pathspec did not match any files.

How do I remove this entry from the status list?

Thank you,
Ben


回答1:


git add -A followed by a commit fixed the problem.



来源:https://stackoverflow.com/questions/5302468/git-status-shows-same-file-twice-but-with-different-path-slash-styles

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!