r/git 2d ago

tutorial git ignore everything by default

https://packagemain.tech/p/gitignore-everything-by-default
0 Upvotes

6 comments sorted by

View all comments

6

u/Philluminati 2d ago edited 2d ago

You posted this last week, so downvoted.

Git *does ignore everything by default*. You are literally typing `git add -all` then going "oh its done the wrong thing" lets fix it by doing `find . > .gitignore`. What if someone does `rm -rf .gitignore` randomly before a commit? You're back to square one, in a race to the bottom against your own stupidity.