git: Your branch and 'origin/master' have diverged, and have 1 and 3 different commits each, respectively.
by MakeTopSite from LinuxQuestions.org on (#6G82X)
... after I had removed last 3 commits and pushed to remote:
Code:git reset HEAD^ --hard
git reset HEAD^ --hard
git reset HEAD^ --hard
git push https://gitlab.com/myname/myproj -fCode:git status
On branch master
Your branch and 'origin/master' have diverged,
and have 1 and 3 different commits each, respectively.
(use "git pull" to merge the remote branch into yours)
nothing to commit, working tree cleanWhat will happen please if I run
Code:git pull ?
Code:git reset HEAD^ --hard
git reset HEAD^ --hard
git reset HEAD^ --hard
git push https://gitlab.com/myname/myproj -fCode:git status
On branch master
Your branch and 'origin/master' have diverged,
and have 1 and 3 different commits each, respectively.
(use "git pull" to merge the remote branch into yours)
nothing to commit, working tree cleanWhat will happen please if I run
Code:git pull ?