Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/git/25.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
git lfs签出在unicode路径为“0”的windows上失败;错误:CreateFile";_Windows_Git_Unicode_Git Lfs_Gitkraken - Fatal编程技术网

git lfs签出在unicode路径为“0”的windows上失败;错误:CreateFile";

git lfs签出在unicode路径为“0”的windows上失败;错误:CreateFile";,windows,git,unicode,git-lfs,gitkraken,Windows,Git,Unicode,Git Lfs,Gitkraken,我已经正确安装了git for windows。召唤 git lfs checkout 在包含特殊字符(C:\Users\myUser\öäü)的路径上使用bash.exe失败,错误为: Error: CreateFile C:\Users\myUser\���: The system cannot find the file specified. 我尝试用GitKraken将LFS文件签出到同一个目录,但失败的原因是相同的错误(我看到GitKraken也调用bash.exe)。当使用git

我已经正确安装了git for windows。召唤

git lfs checkout
在包含特殊字符(C:\Users\myUser\öäü)的路径上使用bash.exe失败,错误为:

Error: CreateFile C:\Users\myUser\���: The system cannot find the file specified.
我尝试用GitKraken将LFS文件签出到同一个目录,但失败的原因是相同的错误(我看到GitKraken也调用bash.exe)。当使用git-bash.exe时,我无法重现错误。两个终端都是MINGW64,即bash.exe的区域设置

$ locale
LANG=
LC_CTYPE="C.UTF-8"
LC_NUMERIC="C.UTF-8"
LC_TIME="C.UTF-8"
LC_COLLATE="C.UTF-8"
LC_MONETARY="C.UTF-8"
LC_MESSAGES="C.UTF-8"
LC_ALL=
而git-bash.exe则打印en_GB.UTF-8。我也试过这么做

MSYSTEM=MINGW64
但不幸的是,这根本没有帮助。 在Mingw-w64模式下使用/usr/bin/mintty会启动一个正常运行的bash,我也无法重现该问题。因此,我想知道如何配置bash.exe以正确运行,我觉得必须有某种方法来实现这一点

编辑: git lfs版本打印

git-lfs/2.12.0 (GitHub; windows amd64; go 1.15.1)
使用git_TRACE=1调用git lfs checkout打印:

$ GIT_TRACE=1 git lfs checkout
14:12:20.043934 exec-cmd.c:237          trace: resolved executable dir: C:/Program Files/Git/mingw64/bin
14:12:20.059555 git.c:704               trace: exec: git-lfs checkout
14:12:20.059555 run-command.c:663       trace: run_command: git-lfs checkout
14:12:20.079718 trace git-lfs: exec: git 'version'
14:12:20.109504 trace git-lfs: exec: git '-c' 'filter.lfs.smudge=' '-c' 'filter.lfs.clean=' '-c' 'filter.lfs.process=' '-c' 'filter.lfs.required=false' 'rev-parse' '--git-dir' '--show-toplevel'
14:12:20.132914 trace git-lfs: exec: uname
14:12:20.189343 trace git-lfs: exec: cygpath '-w' '.git'
14:12:20.208415 trace git-lfs: exec: cygpath '-w' 'C:/Users/myUser/äöü'
14:12:20.243879 trace git-lfs: Error running 'git rev-parse': CreateFile C:\Users\myUser\���: The system cannot find the file specified.
Error: CreateFile C:\Users\myUser\���: The system cannot find the file specified.
...

@bk2204能够在git lfs core中修复它,请参阅:

作为解决方案设置

LC_ALL=C.UTF-8

为我解决了这个问题。

您使用的是什么版本的Git LFS
git lfs版本
会告诉你的。
git lfs/2.11.0(GitHub;windows amd64;go 1.14.2;git 48b28d97)
我还从你的网站上测试了最新版本
git lfs/2.12.0(GitHub;windows amd64;go 1.14.7;git dad7b9e6)
,如果你能提供一个shell脚本在git Bash中重现这个错误,我们希望看到Git LFS问题跟踪程序的错误报告。完成: