我是Git和Github的新手,我只是尝试设置我的桌面客户端,以便能够上传我的项目。
在尝试提交时,我从桌面客户端获取此错误:
Author identity unknown
*** Please tell me who you are.
Run
git config --global user.email "you@example.com"
git config --global user.name "Your Name"
to set your account's default identity.
Omit --global to set the identity only in this repository.
fatal: unable to auto-detect email address (got 'wsm1u@DESKTOP-5ICE6RR.(none)')因此,我使用并获得以下错误:
PS C:\WINDOWS\system32> cd $HOME
PS C:\Users\wsm1u> git config --global user.email "wsm1usa1va1b@gmail.com"
>>
error: could not lock config file C:/desktop/.gitconfig: No such file or directory基本上,我认为问题在于Git在错误的位置搜索配置文件,但我不知道如何让它在其他地方搜索。
以下是我尝试过的解决方案:
git lfs install --force以重置Git配置,这将给出错误消息warning: error running C:\Program Files\Git\mingw64\libexec\git-core\git.exe 'config' '--includes' '--global' '--replace-all' 'filter.lfs.clean' 'git-lfs clean -- %f': 'error: could not lock config file C:/desktop/.gitconfig: No such file or directory' 'exit status 255' Run "git lfs install --force" to reset Git configuration.这是我的系统信息:系统信息
谢谢你的帮助!)
发布于 2022-07-13 20:48:38
TL;博士
长版本
cmd: set HOMEC:\Users\wsm1u>set HOME HOME=C:\desktop HOMEDRIVE=C: HOMEPATH=\Users\wsm1u
git config ‒list并获得正确的名称和返回的电子邮件config ‒list,返回的名字和电子邮件都不见了。https://stackoverflow.com/questions/72901809
复制相似问题