git解决error: The following untracked working tree files would be overwritten by checkout
在IDEA中进行分支切换时,出现如此错误,导致无法正常切换:error: The following untracked working tree files would be overwritten by checkout
通过错误提示可知,是由于一些untracked working tree files引起的问题。所以只要解决了这些untracked的文件就能解决这个问题。
解决方式:
打开SourceTree通过命令行,进入本地版本仓库目录下,直接执行
git clean -d -fx
即可。可能很多人都不明白-d,-fx到底是啥意思,其实git clean -d -fx表示:删除 一些 没有 git add 的 文件;
git clean 参数
-n 显示将要删除的文件和目录;
-x -----删除忽略文件已经对git来说不识别的文件
-d -----删除未被添加到git的路径中的文件
-f -----强制运行
git clean -n
git clean -df
git clean -f
https://blog.csdn.net/lisulong1/article/details/78910727
git解决error: The following untracked working tree files would be overwritten by checkout的更多相关文章
- git checkout 提示 “error: The following untracked working tree files would be overwritten by checkout” 解决
问题描述 Windows 或者 macOS 操作系统中,文件名是不区分大小写的.对于已经提交到仓库中的文件修改文件名的大小写,然后又用 git rm 命令将老文件从 Git 仓库删除掉,并保存下新的文 ...
- Git错误:error: The following untracked working tree files would be overwritten by merge:
[andy@localhost weixin_robot]$ git pull Updating d652d1c..fa05549 error: The following untracked wor ...
- Error pulling origin: error: The following untracked working tree files would be overwritten by...
git在pull时,出现这样的错误的时候,可能非常多人进进行stash.相关stash的请看:Error pulling origin: error: Your local changes to th ...
- 错误 error: The following untracked working tree files would be overwritten by merge:README.md
问题类型 相信很多小伙伴在创建新的git仓库后,会选上添加README.md文件,开始我也没太在意,应该也没有什么问题. 但是当我通过git添加远程仓库,给这个仓库上传代码时,出现了如下问题:erro ...
- Some untracked working tree files would be overwritten by checkout. Please move or remove them before you can checkout. View them
Some untracked working tree files would be overwritten by checkout. Please move or remove them befor ...
- git clean解决 GIT error: The following untracked working tree files would be overwritten
git clean用法:https://www.cnblogs.com/lsgxeva/p/8540476.html :
- git更新代码报错,error: The following untracked working tree files would be overwritten by ch
git忽略大小写导致的, git config --add core.ignorecase true
- git pull 错误:The following untracked working tree files would be overwritten by merge
错误描述: $ git pull origin alphaFrom https://github.com/shirley-wu/HeartTrace * branch alpha ...
- The following untracked working tree files would be overwritten by merge
git pull的时候遇到这样的问题: The following untracked working tree files would be overwritten by merge balabal ...
随机推荐
- linux启动脚本
1. linux启动脚本 : /etc/init.d/脚本例如:/etc/init.d/iptables start init.d/ 下面的每一个文件就是一个启动脚本 2. 以上的/etc/init ...
- 个人作业第五次——Alpha项目测试
这个作业属于哪个课程 https://edu.cnblogs.com/campus/xnsy/2019autumnsystemanalysisanddesign/ 这个作业的要求在哪里 https:/ ...
- HDFS的Shell、java操作
HDFS的Shell操作 1.基本语法 bin/hadoop fs 具体命令 OR bin/hdfs dfs 具体命令 dfs是fs的实现类. 2.命令大全 [Tesla@hadoop102 h ...
- Java-Modifier类常用方法详解
一.Modifier类的定义 Modifier类 (修饰符工具类) 位于 java.lang.reflect 包中,用于判断和获取某个类.变量或方法的修饰符Modifier类将各个修饰符表示为相对应的 ...
- 项目(二) esp32-cam 网页图像人脸
https://randomnerdtutorials.com/esp32-cam-video-streaming-face-recognition-arduino-ide/ ESP32-CAM Pi ...
- round.606.div2
A. Happy Birthday, Polycarp! 这个题意我确实没有看懂. 沃日,我懂了,我感觉我似乎都能切掉这题. B. Make Them Odd 这个我也能看懂.
- openjudge1.3
目录 1.3.1 1.3.2 1.3.3 1.3.4 1.3.5 1.3.6 1.3.7 1.3.8 1.3.9 1.3.10 1.3.11 1.3.12 1.3.13 1.3.14 1.3.15 1 ...
- Nuxt + Vue 全家桶
引子 情由无中有,一旦有了,便万劫不复 简介 “简单却不失优雅,小巧而不乏大匠”. Vue.js 是一个JavaScriptMVVM库,是一套构建用户界面的渐进式框架.它是以数据驱动和组件化的思想构建 ...
- js时间练习
编写代码,将当前日期按"2017-12-27 11:11 星期三"格式输出 var t1 = new Date(); console.log(t1.toLocaleString() ...
- 一起学Makefile(一)
make和makefile makefile文件帮助我们记录了整个项目工程的所有需要编译的文件列表,这样我们在编译时仅需要输入简单的make命令就能编译出我们期望的结果. makefile文件反映了整 ...