From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jakub Narebski Subject: Re: [1.8.0] Tracking empty directories Date: Thu, 3 Feb 2011 00:52:43 +0100 Message-ID: <201102030052.44940.jnareb@gmail.com> References: <7vzkqh8vqw.fsf@alter.siamese.dyndns.org> <4928FF12-E593-4CDB-AC68-B4078CC5920E@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-2 Content-Transfer-Encoding: QUOTED-PRINTABLE Cc: Jay Soffian , "git@vger.kernel.org" To: David Aguilar X-From: git-owner@vger.kernel.org Thu Feb 03 00:53:00 2011 Return-path: Envelope-to: gcvg-git-2@lo.gmane.org Received: from vger.kernel.org ([209.132.180.67]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1PkmVP-0003LG-Mr for gcvg-git-2@lo.gmane.org; Thu, 03 Feb 2011 00:53:00 +0100 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755492Ab1BBXwz convert rfc822-to-quoted-printable (ORCPT ); Wed, 2 Feb 2011 18:52:55 -0500 Received: from mail-wy0-f174.google.com ([74.125.82.174]:34110 "EHLO mail-wy0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754475Ab1BBXwy (ORCPT ); Wed, 2 Feb 2011 18:52:54 -0500 Received: by wyb28 with SMTP id 28so609265wyb.19 for ; Wed, 02 Feb 2011 15:52:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:from:to:subject:date:user-agent:cc:references :in-reply-to:mime-version:content-type:content-transfer-encoding :content-disposition:message-id; bh=EMr7HSMvVKRKpD1WgPxrffF/1rLgDgyDA6x4/CMBrHg=; b=R7N2t53NR+XaGpgUp2WP4vRHm2BezxncsQUxqoUVWx2wuOQnnVFJs6jqToArVrFUQk GXS0/IvWA+IFG+WhN+7iP1hIxw++GBVDA3PYk5RFphwNcUtbSFe4Uf8JqI/ew6Ph7/z+ gmJeFwJxeJknytoZWu5ii5779jnjaEm8aIVnY= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:subject:date:user-agent:cc:references:in-reply-to :mime-version:content-type:content-transfer-encoding :content-disposition:message-id; b=hJOdGu/9c1Y1MHzvQTNNFCeTU+kn0iTWx2O6DMZ3XzQVa/B2W+K9VSNYn3xo+H5Fz3 5zyj7X3dmBEpDtS3Gj+KUD2wBGWb5E+n926YBGOOyLxVBUHZATbtZxVWohuboKTWMjO0 jHisOX1I9EYW3x2CNqqTMNTAKcNDklzkSEmwc= Received: by 10.227.156.137 with SMTP id x9mr8322978wbw.108.1296690773077; Wed, 02 Feb 2011 15:52:53 -0800 (PST) Received: from [192.168.1.13] (abvv233.neoplus.adsl.tpnet.pl [83.8.219.233]) by mx.google.com with ESMTPS id n11sm112419wej.19.2011.02.02.15.52.50 (version=TLSv1/SSLv3 cipher=RC4-MD5); Wed, 02 Feb 2011 15:52:51 -0800 (PST) User-Agent: KMail/1.9.3 In-Reply-To: <4928FF12-E593-4CDB-AC68-B4078CC5920E@gmail.com> Content-Disposition: inline Sender: git-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org Archived-At: Dnia czwartek 3. lutego 2011 00:33, David Aguilar napisa=B3: > On Feb 2, 2011, at 3:23 PM, Jay Soffian wrote: >> On Wed, Feb 2, 2011 at 6:56 AM, Jakub Narebski wr= ote: >>> >>> The problem with backward compatibility is twofold. First and more >>> important is while git supports empty tree object (it has it =20 >>> hardcoded >>> for some time, as it is necessary e.g. for initial diff, or merging >>> unrelated branches without common ancestor), and there is no proble= m >>> with entry for empty tree in a tree object >>> >>> 040000 tree 22d5826c087c4b9dcc72e2131c2cfb061403f7eb empty >>> >>> there is (supposedly) problem when checking out such tree (see emai= l >>> referenced above) with an old git. >>> >>> Second is that tracking empty directories would require extension =20 >>> to the >>> git index (storing trees in index, like we store submodules)... but= =20 >>> that >>> is purely local matter. >> >> Instead of using an empty tree, construct a tree containing a single >> sentinel file whose contents are a suitable warning not to delete/ed= it >> said file using pre-1.8.0 git. Meanwhile git-1.8.0 never writes the >> file to the filesystem. Too ugly? Too ugly. > I don't like where this is going. Users are not always right. =20 > Touch .gitignore and be done with it. This is a big change with =20 > negligible benefits. I don't understand why this is needed. Two issues: first is interaction with other SCM which keep empty files (or keep empty files when requested). Second is skeleton of directory structure automatically generated by some git-unaware tool. I've never felt the need but more than 50% of Git User's Survey 2010 responders did. --=20 Jakub Narebski Poland