Git: fatal: Pathspec is in submodule
出现是问题:
git提交代码是出现fatal: Path 'directory/file' is in submodule 'directory''错误
Removing the directory from git and adding it again worked for me: git rm --cached directory
git add directory This works if you purposefully removed the .git directory because you wanted to add directory to your main git project. In my specific case, I had git cloned an extension and ran git add . without thinking too much. Git decided to create a submodule, which I didn't like. So I removed directory/.git and ran into Git: fatal: Pathspec is in submodule. I couldn't find out how to remove the submodule stuff. Fixed with the two lines above.
Git: fatal: Pathspec is in submodule的更多相关文章
- git fatal: Path 'XXX' is in submodule 'XXX'错误
easyswoole项目的 vendor/easyswoole/socket/这个项目怎么都无法添加到git目录里面. 报错: Administrator@PhpServer MINGW64 /z/w ...
- git rm–r folder fatal:pathspec "" did not match any files
问题描述: 某年某月某日,在查看git库的时候,发现文件的分布和文件夹的名字是极其不合理的,所以移动和重命名了某些文件. 在删除(git rm –r folder)一个空文件夹的时候,出现错误:fat ...
- Git无法删除文件问题:fatal: pathspec 'readme.txt' did not match any files
在使用Git时,不小心创建了一个不需要的文件,想要删除一个文件时,出现了错误: fatal: pathspec 'readme.txt' did not match any files 原因是新建的这 ...
- git 添加add readme.txt 报fatal: pathspec 'readme.txt' did not match any files错误
刚刚接触git版本管理器,跟着廖雪峰老师的git教程学习,在创建一个新的文件时,使用的是$ git add readme.txt指令,但是报出fatal: pathspec 'readme.txt' ...
- git fatal: remote origin already exists. 报错解决
在研究git的时候,随便输了个 git remote add origin xxx; 然后再真正add 远程仓库的时候,报了git fatal: remote origin already exist ...
- 【Git】git clone报错 git fatal: Unable to find remote helper for 'https'
[参考资料] https://stackoverflow.com/questions/8329485/unable-to-find-remote-helper-for-https-during-git ...
- Git出现 fatal: Pathspec 'xxx' is in submodule 'xxx' 异常的解决方案
今天在使用git的时候,发现无论怎么改.gitignore文件都无法添加文件到版本控制,最后发现是缓存的原因,需要删除缓存再重新add git rm -rf --cached xxx
- git中报错---fatal: pathspec 'readme.txt' did not match any files
1.git安装 git官网下载最新版本,一键安装或custom install. 2.会弹出一个类似的命令窗口的东西,就说明Git安装成功. 3.安装完成后,还需要最后一步设置,在命令行输入如下--- ...
- 解决git add README.md 时报错 fatal: pathspec 'README.md' did not match any files
解决办法一: 直接在远程仓库创建然后在本地$ git pull origin master 解决办法二: 换成$ touch README.md在本地创建修改后再commit push上去
随机推荐
- Cantor展开式
X=an*(n-1)!+an-1*(n-2)!+...+ai*(i-1)!+...+a2*1!+a1*0! 其中,a为整数,并且0<=ai<i(1<=i<=n).这就是康托展开 ...
- Go语言之进阶篇响应报文测试方法
1.响应报文测试方法 示例: package main import ( "fmt" "net/http" ) //服务端编写的业务逻辑处理程序 func my ...
- iOS蓝牙空中升级(固件升级)
空中升级又叫固件升级,指你手机从服务器下载下来的包或者数据,通过蓝牙传输给你的外设升级固件.如果你能把蓝牙的基础搞懂,其实也并不是很难,我在这里只不过提供一下思路. 空中升级略难的地方在于数据处理和交 ...
- HTML中的转义字符 (转)
HTML中<, >,&等有特殊含义,(前两个字符用于链接签,&用于转义),不能直接使用.使用这三个字符时,应使用它们的转义序列,如下所示: & 或 & &a ...
- vue按需引入echarts
下载安装echarts包:npm install echarts -D 一.全局引入 main.js中配置 import echarts from 'echarts' //引入echarts Vue. ...
- jQuery UI全教程之一(dialog的使用教程)
jQuery UI目前的版本已经更新到了1.8.7.个人感觉和easyui相比起来,jQuery UI在界面的美观程度和可定制型更强一些.所以再次将一些jQuery UI组件的用法说明一下,方便日后查 ...
- 4.3 使用 SQL 语句操作数据框
下载并安装 “sqldf” 包 library(sqldf) newData <- sqldf("select * from mtcars where carb=1 order by ...
- PHP使用DOM XML操作XML[总结]
1.前言 XML树状层次结构鲜明,非常适合作为配置文件.PHP中可以使用DOM XML来操作XML.本文总结一下PHP使用DOM XML创建.添加节点.查询XML文件. 2.使用DOM XML XML ...
- [转]xshell实现端口转发
原文: https://www.cnblogs.com/linxizhifeng/p/8657795.html https://blog.csdn.net/qq_34039315/article/de ...
- THINKPHP 验证码不显示
最近同事将我之前使用Thinkphp做的一个项目从香港服务器迁移到国内,但却遇到了图片验证码不显示的问题 但我确认了以下可能的问题后还是没有解决 PHP是否已经安装GD库支持: 输出之前是否有任何的输 ...