pathspec did not match any file known to git

来源:互联网 发布:c语言入门经典 编辑:程序博客网 时间:2024/05/01 03:04

xcode的本地项目中的文件夹删除,新增或者重命名后,如果通过git提交代码时就会出现"pathspec did not match any file known to git"错误,这时可以先commit,后push。如下图所示,不要勾选"Push to remote"选项,输入commit message后,直接点'commit 21 files'。


然后,在xcode菜单栏的'Source Control'中点'Push...'选项就能正常将代码推送到服务器中。


0 0