From mboxrd@z Thu Jan 1 00:00:00 1970 From: Junio C Hamano Subject: Re: msysgit: merge, stat Date: Mon, 13 Aug 2007 12:54:55 -0700 Message-ID: <7vzm0vfbw0.fsf@assigned-by-dhcp.cox.net> References: <2C573942-DD22-46EC-AE4A-1334450A7C4D@zib.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Steffen Prohaska , Git Mailing List To: Johannes Schindelin X-From: git-owner@vger.kernel.org Mon Aug 13 22:10:31 2007 Return-path: Envelope-to: gcvg-git@gmane.org Received: from vger.kernel.org ([209.132.176.167]) by lo.gmane.org with esmtp (Exim 4.50) id 1IKg0D-0008Lf-62 for gcvg-git@gmane.org; Mon, 13 Aug 2007 21:55:01 +0200 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1760733AbXHMTzA (ORCPT ); Mon, 13 Aug 2007 15:55:00 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1761818AbXHMTy7 (ORCPT ); Mon, 13 Aug 2007 15:54:59 -0400 Received: from fed1rmmtao101.cox.net ([68.230.241.45]:62475 "EHLO fed1rmmtao101.cox.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1759602AbXHMTy5 (ORCPT ); Mon, 13 Aug 2007 15:54:57 -0400 Received: from fed1rmimpo01.cox.net ([70.169.32.71]) by fed1rmmtao101.cox.net (InterMail vM.7.08.02.01 201-2186-121-102-20070209) with ESMTP id <20070813195457.YZNY5405.fed1rmmtao101.cox.net@fed1rmimpo01.cox.net>; Mon, 13 Aug 2007 15:54:57 -0400 Received: from assigned-by-dhcp.cox.net ([68.5.247.80]) by fed1rmimpo01.cox.net with bizsmtp id bXuv1X00G1kojtg0000000; Mon, 13 Aug 2007 15:54:56 -0400 In-Reply-To: (Johannes Schindelin's message of "Mon, 13 Aug 2007 17:45:07 +0100 (BST)") User-Agent: Gnus/5.110006 (No Gnus v0.6) Emacs/21.4 (gnu/linux) Sender: git-owner@vger.kernel.org Precedence: bulk X-Mailing-List: git@vger.kernel.org Archived-At: Johannes Schindelin writes: > On Sun, 12 Aug 2007, Steffen Prohaska wrote: > >> After a 'git merge' in msysgit some stat information of the index >> doesn't match the working tree. Thus 'git diff' looks at files, >> which it shouldn't look at. I need to do a >> 'git update-index --refresh' before everything's in sync. >> >> Is this a know issue? Do other experience the same? > > Yes, it is. The real issue is that the index is out of date, and the full > speed of git is not available until a refresh (which you can have with a > "git status", too). Wait a minute. What does the above "After a 'git merge'" exactly mean? After a successful automerge that made a commit, of stopped in the middle because of conflicts? I am getting an impression that Steffen is talking about the former, but if that is the case, somebody is seriously confused. When "merge-recursive" with a 3-way file level merge in core writes the result out to the work tree, it uses a cache entry that is stat clean (see merge-recursive.c::make_cache_entry(), refresh option is passed and it calls refresh_cache_entry() to obtain the cached stat bits). The traditional "read-tree -m -u" followed by merge-one-file of course runs "git update-index" inside merge-one-file script and cleanly merged paths should be stat clean after a merge.