push declined due to email privacy restrictions

使用git push到Github网站的时候提示:

push declined due to email privacy restrictions

原因

在Github设置里有一个隐私选项

Block command line pushes that expose my email

所以如果本地的git config里email地址与Github账号相同,为了防止个人邮件地件泄漏,git push会被拒绝。

解决方法

  1. 关闭这个选项
  2. 更改邮件地址
posted @ 2017-06-19 14:44  2021年的顺遂平安君  阅读(805)  评论(0编辑  收藏  举报