git提交的时候如果遇到does not match your user account

除了使用下面的命令重新设置账号以外
git config --global user.name "Your Name"
git config --global user.email you@example.com
还需要
git commit --amend --reset-author
否则是不会有效果的
当然,如果能在Gerrit里面进行配置,配置 'Forge Committer' 和 'Forge Author' 访问权限也是能够解决的。
本文介绍了当遇到Git提交时作者信息不匹配的问题时的解决办法。不仅提供了如何正确设置Git全局用户名称和邮箱的方法,还指出了需要使用特定命令来修正已提交的内容才能生效。此外,文中还提到了在Gerrit中配置‘ForgeCommitter’和‘ForgeAuthor’访问权限作为另一种解决方案。
1066





