git 使用经验

1. git reset --hard *** failing

1. git reset --hard ***version failing

错误信息:fatal: Could not reset index file to revision 'origin/master'

解决方法: 使用下面2条命令后,

$ git gc
$ git reset
Before git reset ; I had to do rm .git/index。 再回退到指定的版本。 $ git reset --hard <target_branch>

posted @ 2023-10-09 11:59  fire909090  阅读(84)  评论(0编辑  收藏  举报