Re: Git log can not show history before rename

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

 



2009/1/30 Frank Li <lznuaa@xxxxxxxxx>:
> mkdir tt3
> cd tt3
> git init-db

"git init"

> touch a.c
> git add a.c
> git commit -a -m "test1"
>
> git mv a.c b.c
> git commit -a -m "rename"
>
> modify b.c
> git commit -a -m "test2"
>
> git log -C -M -- b.c
[...]
> I can't get history before rename.

You asked to restrict the search to the b.c path.

You want:

git log --follow -- b.c

Man git-log:
       --follow
           Continue listing the history of a file beyond renames.

HTH,
Santi
> --
> To unsubscribe from this list: send the line "unsubscribe git" in
> the body of a message to majordomo@xxxxxxxxxxxxxxx
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[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]

  Powered by Linux