Re: git log history simplification problem

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Feb 04, 2014 at 06:37:13PM +0100, Miklos Vajna <vmiklos@xxxxxxxxxxxxxxx> wrote:
> But then I run:
> 
> git grep 'mnTitleBarHeight =' sd
> 
> and it's not there. Am I missing something, as in e.g. even with
> --full-history git-log does some simplification?

I tried to reproduce this with a repo from scratch, and it seems my
problem is the following:

1) "A" creates a feature branch
2) "A" works on it, and in the meantime master progresses as well
3) "A" merges master to the feature branch
4) "A" does some additional changes, and -- in an evil way -- uses "git
commit -a --amend" to squeeze these into the merge commit
5) "B" (that's me) comes and try to find out where a string got deleted,
but can't.

Here is a reproducer script:

----
rm -rf scratch
mkdir scratch
cd scratch
git init
echo -e "a\na\na\na\na\na\na\na\n" > a
git add a
git commit -m init
git branch feature
echo "b" >> a
git add a
git commit -m "more master changes"
git checkout feature
sed -i '1iXXX' a # insert first row
git add a
git commit -m "feature"
git merge -m merge master
sed -i '1d' a # delete first row
git add a
git commit --amend -m "merge"
----

I now know that the XXX got removed by the merge commit, but how can I
see it that I'm right? If I run 'git log --all -p' in the result, I see
that XXX got inserted by one commit, now I don't have it, but I don't
see any deletion, which confuses me.

Any ideas? :-)

Thanks,

Miklos

Attachment: signature.asc
Description: Digital signature


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]