Reputation: 120
I have checked out a new branch and I have made a commit. In that commit there is one file 'A' with no changes but still showing as changed. After that I am using
git fetch
command I get some commits from upstream, then I use
git rebase
As I do it I get one conflict in file 'A'.
I add it and I use
git rebase --continue
after this
git rebase
process is done and my changes from commit are gone.
What am I doing wrong?
Upvotes: 3
Views: 9057
Reputation: 34205
If the file was ever committed, have a look at the output of git reflog
. It will show you all commits git created lately. That includes commits that were either created temporarily, or that are not reachable anymore via branches.
If A
was ever committed, one of the listed commits should include it. If you had only local changes and rebased anyway, I'm not sure you can recover it at all.
Upvotes: 4