Hi,
> $ git stash
> $ git fetch
> $ git rebase origin/master
> $ git stash apply
> <resolve conflicts>
> $ git stash clear
> $ git reset
Note that "git stash clear" is a dangerous command. I recommend to use it
only after "git stash list" and/or "git status".
I just did this:
$ git stash
$ git pull
$ git stash apply
$ git stash clean ; typo!
$ git stash clear ; fatal correction to typo!
and lost 20 modified files. Well, not really lost. Just took me a while to
recover them by
- looking for the most recently changed files in .git/objects/,
- use "git cat-file blob xxxx" on each,
- assign the blobs to file names.
Is there some shorthand for this process, such as a "git-recover" command?
Bruno