当前位置:   article > 正文

git1 - git中提示error: pathspec ‘xxx‘x did not match any file(s) known to git

error: pathspec

1. 问题概述

最近在git中使用commit,将文件暂存到本地库时,有时候会报下面的错误

$ git commit -v '第一次提交'
error: pathspec '第一次提交' did not match any file(s) known to git
  • 1
  • 2

而通过 ‘git status’ 进程状态的查看是没有问题的,可以发现 git add xx 是成功的。

$ git status
On branch master

No commits yet

Changes to be committed:
  (use "git rm --cached <file>..." to unstage)
        new file:   test1.c
        new file:   test2.c
        new file:   test3.c
        new file:   test4.c
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/小桥流水78/article/detail/927364
推荐阅读
相关标签
  

闽ICP备14008679号