问题:
error: open("kyai_one_button_deploy/update_prj/temp_solution/update_pack_make/web/ky_upgrade_web/resource/web/expressServer/node_modules/compressing/node_modules/iconv-lite/encodings/tables/gb18030-ranges.json"): Filename too long
kyai_one_button_deploy/update_prj/temp_solution/update_pack_make/web/ky_upgrade_web/resource/web/expressServer/node_modules/compressing/node_modules/iconv-lite/encodings/tables/gb18030-ranges.json
196字节而已啊
不过加上前面,绝对路径可能多点:
/e/20230228_HuiYuanKuangNaoCwProject/testKYAI/coding/kyai_2.0_tml/kyai_one_button_deploy/update_prj/temp_solution/update_pack_make/web/ky_upgrade_web/resource/web/expressServer/node_modules/compressing/node_modules/iconv-lite/encodings/tables/gb18030-ranges.json
有262字节,而在 Windows 系统上,Git 默认的文件路径长度限制是 260 个字符。
原因及解决方法:
这个问题通常是由于文件名过长导致的。解决方法有两种:
-
缩短文件名
可以尝试缩短文件名,使其不超过Git所允许的最大长度。 -
修改Git配置
可以通过修改Git配置来增加Git所允许的最大长度。可以使用命令git config --system core.longpaths true
来增加Git所允许的最大长度。
无论哪种方法,都需要重新执行git add
命令来将文件添加到Git中。
参考文章:git报错 Filename too long的解决方法
我用git bash执行的时候没有权限。。。后来我用windows控制台搞定了,