我是靠谱客的博主 诚心唇膏,这篇文章主要介绍解决 Github用户名 变为 invalid-email-address 问题,现在分享给大家,希望可以做个参考。

解决 Github用户名 变为 invalid-email-address 问题

952608-20170125103931831-700915641.png

If the identity used for this commit is wrong, you can fix it with:

复制代码
1
git commit --amend --author='Your Name <you@example.com>'

一、首页解决操作

补上 Github 邮箱信息:vim $HOME/.gitconfig

复制代码
1
2
3
git config --global user.name "username" git config --global user.email "username@email.com" git push origin master

952608-20170125104558347-1819954022.png

这时候我们就可以发现,首页已经恢复正常了。

注意:不要使用 "git init" 初始化命令!

二、内容页解决

查看 Github 日志:bash -c "git log"

952608-20170125111211425-1263232178.png

复制代码
1
2
git rebase --interactive 4d49c2e --interactive/-i 4d49c2e/4d49c2e995be282f8335(略)cde4194e

952608-20170125112321737-395385267.png

复制代码
1
2
3
4
5
git commit --amend --reset-author git rebase --continue git rebase --continue git rebase --continue

952608-20170125112819597-238893902.png

复制代码
1
git push -f 强制覆盖推到远端

注意:平常操作并不会用到上述所有命令,用不好大家的 commit 会丢失或者被篡改的

感兴趣,可以新建个 repo 研究下~

952608-20170125104902034-95526425.png

小猫咪问你,解决了嘛~

一些其他

Git版本控制

创建仓库
git init
git clone
git config

保存修改

git add
git commit

查看仓库

git status
git log –oneline

撤销修改

查看之前的commit

git checkout
git checkout
git checkout

撤销公共修改

git revert

撤销本地修改

git reset
git clean

重写Git历史记录

git commit –amend
git rebase
git reflog

Git协作开发

分支

git branch
git checkout
git merge

仓库同步

git remote
git fetch
git pull
git push

转载于:https://www.cnblogs.com/itxdm/p/6349239.html

最后

以上就是诚心唇膏最近收集整理的关于解决 Github用户名 变为 invalid-email-address 问题的全部内容,更多相关解决内容请搜索靠谱客的其他文章。

本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
点赞(52)

评论列表共有 0 条评论

立即
投稿
返回
顶部