Windows版Git中的文件名太长

耗尽温柔 提交于 2020-08-05 02:59:25

问题:

I'm using Git-1.9.0-preview20140217 for Windows. 我正在Windows上使用Git-1.9.0-preview20140217 As I know, this release should fix the issue with too long filenames. 据我所知,此版本应解决文件名过长的问题。 But not for me. 但是不适合我。

Surely I'm doing something wrong: I did git config core.longpaths true and git add . 当然,我做错了:我做了git config core.longpaths truegit add . and then git commit . 然后git commit Everything went well. 一切顺利。 But when I now do a git status , I get a list of files with Filename too long , for example: 但是,当我现在执行git status ,会得到文件Filename too long的文件列表,例如:

node_modules/grunt-contrib-imagemin/node_modules/pngquant-bin/node_modules/bin-wrapper/node_modules/download/node_modules/request/node_modules/form-data/node_modules/combined-stream/node_modules/delayed-stream/test/integration/test-handle-source-errors.js: Filename too long

It is quite simple to reproduce for me: just create a Yeoman web application with the Angular generator ("yo angular") and remove node_modules from the .gitignore file. 对我来说,复制非常简单:只需使用Angular生成器(“ yo angular”)创建Yeoman Web应用程序, node_modules.gitignore文件中删除node_modules Then repeat the aforementioned Git commands. 然后重复上述Git命令。

What am I missing here? 我在这里想念什么?


解决方案:

参考一: https://stackoom.com/question/1Wixa/Windows版Git中的文件名太长
参考二: https://oldbug.net/q/1Wixa/Filename-too-long-in-Git-for-Windows
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!