[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: git: avoiding merges, rebasing
From: |
Bruno Haible |
Subject: |
Re: git: avoiding merges, rebasing |
Date: |
Tue, 2 Oct 2007 13:50:54 +0200 |
User-agent: |
KMail/1.5.4 |
Hello Benoit,
> > $ 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
>
> I don't really see how and why you "lost 20 modified files".
I lost modifications to 20 files. "git stash clean" moved these modifications
into a stash named "clean", and "git stash clear" killed it.
> > Is there some shorthand for this process, such as a "git-recover"
> > command?
>
> you can run git fsck and look for
> a dangling commit (which can be inspected with git show <sha1>) where
> you are most likely to find your stash (unless you run git-gc or this
> sort of thing).
Cool! This information would be worth mentioning in the git-stash manual
page or in an FAQ. It can be a real life-saver.
> Someone just told me on IRC that you can also use git lost-found
> (which worked for me).
"git lost-found" does not work well for me: I stopped it after it ate
10 minutes of CPU time without producing a result. If you think that's
a bug (endless loop?), you can find the repository I was working on at
http://www.haible.de/bruno/gnulib-testgit.tar.gz
Bruno
- Re: git: avoiding merges, rebasing, Bruno Haible, 2007/10/01
- Re: git: avoiding merges, rebasing, Benoit SIGOURE, 2007/10/02
- Re: git: avoiding merges, rebasing,
Bruno Haible <=
- Re: git: avoiding merges, rebasing, Eric Blake, 2007/10/02
- stash clear, was Re: git: avoiding merges, rebasing, Johannes Schindelin, 2007/10/19
- Re: stash clear, was Re: git: avoiding merges, rebasing, Miles Bader, 2007/10/23
- Re: git: avoiding merges, rebasing, Benoit SIGOURE, 2007/10/02
- Re: git: avoiding merges, rebasing, Bruno Haible, 2007/10/03
- Re: git: avoiding merges, rebasing, Bruno Haible, 2007/10/03