Table of Contents
Recover Lost Stashes or Commits
Just Do It
- Find them from unreachable commit and filter it.
git fsck --unreachable | grep commit | cut -d ' ' -f3 | xargs git log --merges --no-walk
- Put the stash back where it comes from.
git update-ref refs/stash <hash> -m --create-reflog "poor little stash"
or Apply the stash to working copy.
git stash apply <hash>