by yjftsjthsd-h · 9mo ago · 0 comments
touch build/.gitkeep
git add build/.gitkeep
git commit build/.gitkeep
And that's it? There's no need to exclude anything.".gitkeep" is just a human thing; it would work the same if you called it ".blahblah".
So their pitch is that if you want to explicitly keep the existence of the directory as a committed part of the repo, you're better off using the actual .gitignore functionality to check in the .gitignore file but ignore anything else in the directory.
I don't find it amazingly compelling; .gitkeep isn't breaking anything.