tags:

views:

65

answers:

2

I had a lot of local changes.

I just accidentally did

git merge another_branch
git reset --hard HEAD^

on a lot of work. :( with the intention I didn't want the merged changes in here.

How do I recover the original state?

No, the local changes were never committed/stashed.

No way?

+1  A: 

If the changes had never been committed/stashed/staged, then you're out of luck. If they have, then you should be able to git your changes back by looking for them in git reflog.

jamessan
A: 

Although the uncommitted modifications to tracked files will have been lost, I think any untracked files will still be around unless you subsequently deleted them. But you probably already knew this.

Eric W.