Re: [RFC PATCH] Re: Empty directories...
- From
David Kastrup <dak@gnu.org>
- Date
- Jul 19, 2007, 12:24 UTC
- Message-ID
- <86wswwa8ej.fsf@lola.quinscape.zz>
- In-Reply-To
- <Pine.LNX.4.64.0707191310430.14781@racer.site>
Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:
Show 22 quoted lines
> Hi, > > On Thu, 19 Jul 2007, Tomash Brechko wrote: > >> A year or so ago I too would strongly advocate the need of tracking >> empty directories, permissions et al., it seemed so "natural" and "plain >> obvious" to me back then. But since that time I learned to appreciate >> the "contents tracking" approach, and now view directories (paths in >> general) only as the means for Git to know where to put the contents on >> checkout. This, BTW, is consistent with how Git figures container >> copies/renames. > > Thank you. It is my impression, too, that after a while it becomes > obvious what is good and what is not. > > FWIW I just whipped up a proof-of-concept patch (so at least _I_ cannot be > accused of chickening out of writing code): > > This adds the command line option "--add-empty-dirs" to "git add", which > does the only sane thing: putting a placeholder into that directory, and > adding that. Since ".gitignore" is already a reserved file name in git, > it is used as the name of this place holder.
But that means that checkout will create a file .gitignore in previously empty directories, doesn't it?
I think that the placeholder name should rather be ".".
-- David Kastrup