git log date filter behavior with --date-order

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

 



Hi,

I’ve faced a strange behavior when filtering git log by date.

When used with “--date-order” it gives significantly less results that when used without that option:

#  git log --pretty=oneline --remotes "--after=Wed May 20 23:00:00 MSK 2015" "--before=Fri May 22 00:00:00 MSK 2015" -- | wc -l
      85
#  git log --pretty=oneline --remotes "--after=Wed May 20 23:00:00 MSK 2015" "--before=Fri May 22 00:00:00 MSK 2015" --date-order -- | wc -l
      25

My assumption is that git log walks from the specified heads down to the past until it finds a commit which commit date matches the filter. Then it continues until it finds a commit which commit date doesn’t match the filter. Is it true?

Commits from “matching” and “unmatching” parts of the output are located in different branches which are being developed in parallel. 
AFAIU the flag “--date-order” is meant to place commits from different branches near each other, if they were performed at the same time.

But when I looked both at the “matching" and the “unmatching” commits in the whole `git log --date-order` view, I’ve noticed that they are placed really far away from each other (with about 4K commits between them).

Could you please give me a hint, why can git log --date-order behave like that? 

I’ll be happy to provide more details if needed. 

Thanks a lot!
Kirill.--
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]