Reputation: 27
My operation is :
and I found my changes disappeared.
Upvotes: 1
Views: 33
Reputation: 1323973
When you checkout (using git switch
by the way) origin/a
, you are in detached head mode.
You should:
git switch a
to create a local branch a
linked to origin/a
git branch -avv
to check a exists, and has origin/a as upstreamgit reflog
to find the commit you have donegit cherry-pick <sha1>
to get that commit on your branch a
Upvotes: 1