From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS31976 209.132.180.0/23 X-Spam-Status: No, score=-3.9 required=3.0 tests=AWL,BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI, RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_NONE shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by dcvr.yhbt.net (Postfix) with ESMTP id DA0161F5A2 for ; Sun, 2 Feb 2020 21:45:15 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726989AbgBBVmp (ORCPT ); Sun, 2 Feb 2020 16:42:45 -0500 Received: from ikke.info ([178.21.113.177]:57784 "EHLO vps892.directvps.nl" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726967AbgBBVmp (ORCPT ); Sun, 2 Feb 2020 16:42:45 -0500 Received: by vps892.directvps.nl (Postfix, from userid 1008) id 00F5D4400DC; Sun, 2 Feb 2020 22:42:43 +0100 (CET) Date: Sun, 2 Feb 2020 22:42:43 +0100 From: Kevin Daudt To: Chris Packham Cc: GIT Subject: Re: git log FILE vs git log --follow FILE missing commits Message-ID: <20200202214243.GA1090206@alpha> Mail-Followup-To: Kevin Daudt , Chris Packham , GIT References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Sender: git-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org On Mon, Feb 03, 2020 at 10:27:52AM +1300, Chris Packham wrote: > Hi, > > I've just hit a problem where git log doesn't want to tell me about a > commit that touches a specific file. > > I wanted to point someone at a particular change that I knew was made > to a file so I fired up 'git log FILE' and to my surprise it wasn't > listed. I wondered if I had remembered wrong so went grepping to > confirm the change was in the file I thought it was, sure enough it > was there. > > Poking around a bit I found that git log --follow FILE shows the > intended commit but git log FILE doesn't (it does show other commits > that touch the file, most of which have tags if that's significant). > The file hasn't been renamed so I didn't really expect --follow to > change any behavior. > > The version of git I'm using is 2.25.0 from > http://ppa.launchpad.net/git-core/ppa/ubuntu bionic main. I also tried > 2.24.1 and 2.23.1 with the same problem. > > Any suggestions for tracking this down? > > Thanks, > Chris Hey Chris, Try `git log --full-history FILE`. When passing a path to `git log` will enable history simplification, which might explain why certain commits are not shown. Kind regards, Kevin.