News for hackers. Stuff that matters.
Re:Is Git Irreplaceable? (2019) by adrianmsmith on Tuesday January 07, 2020 @07:35AM (#21979337)
Another thing that Git does not track -

I saw a web designer check in a huge hierarchy of empty directories which would be the structure of the new project that their team should work on. They were quite surprised when it didn't show up on any of the other designer's computers after a "pull". They had to go to the "Git guru" for help.

Windows and Mac both have directories as a major fundamental concept. Everyone knows them and is familiar with them. Subversion tracks directories. Git does not.

Re:Is Git Irreplaceable? (2019) by ori_b on Tuesday January 07, 2020 @09:24AM (#21980125)
I also can't figure out why it doesn't: An empty tree object should be sufficient to do the job. I actually had to write extra code in git9[1] to avoid accidentally allowing empty directories.

[1] https://github.com/oridb/git9

Re:Is Git Irreplaceable? (2019) by debaserab2 on Tuesday January 07, 2020 @10:22AM (#21980717)
According to this[1], which I think might be an official FAQ:

> Currently the design of the Git index (staging area) only permits files to be listed, and nobody competent enough to make the change to allow empty directories has cared enough about this situation to remedy it.

[1] https://git.wiki.kernel.org/index.php/GitFaq#Can_I_add_empty...

Re:Is Git Irreplaceable? (2019) by ori_b on Tuesday January 07, 2020 @03:27PM (#21984424)
Hm. I should see how git behaves when it gets a repository with empty directories. If it doesn't blow up, I may just add support -- it'd be useful for me.
Re:Is Git Irreplaceable? (2019) by eyegor on Tuesday January 07, 2020 @09:13AM (#21980034)
It kind of does, iff you have a file there. In which case it tracks the path to the file, and then creates the relevant directory structure to get to it.

Of course git is also incredibly painful and brittle if you want "exclude/except" behavior on the gitignore involving subdirectories.