Android Studio Git Commit failed 错误解决办法之author ‘Kearne‘ is not ‘Name <email>‘and matches no existing

简介

这些天新建Android Studio工程的时候需要commit和push到github上,却报错无法commit,错误信息如下

16:44	Commit failed with error
			0 files committed, 40 files failed to commit: 实现连接ranye服务器并publish topic
			--author 'Kearney' is not 'Name <email>' and matches no existing author

我人都傻了,之前commit了几十次的这个名称没啥毛病哇。。。。
然后我也试了单独输入邮箱或者用户+邮箱。。结果也是失败了。。。。。

解决办法

查看git用户信息

查看用户名

$ git config user.name

查看邮箱

$ git config user.email

比如我的信息为Kearney,邮箱为[email protected]
那么在AS中commit填写Author的时候格式为:

UserName<Mail>

commit && push

注意是尖括号。。。我之前填成圆括号,怪不得fail
在这里插入图片描述
成功之后我想po个图

16:47	Pushed master to new branch origin/master

References

  • https://blog.csdn.net/xyc_csdn/article/details/72865266
  • https://blog.csdn.net/LVXIANGAN/article/details/108276443

猜你喜欢

转载自blog.csdn.net/weixin_43031092/article/details/108472209