Hacker News new | ask | show | jobs
by RupertWiser 1492 days ago
Do you know about .git/info/exclude? It only exists in your local git file so it isn’t shared with a remote repo and achieves this same purpose.
3 comments

I also (mis)used .gitignore before I realised that there was an easy way to ignore stuff that I have locally without having to commit/ignore a .gitignore file.
I didn't! Good to know, even if my way is really quick and simple to set up so I might continue doing the same. Thanks!
Not at a term, but would this prevent `git clean -fdx` from removing the dir? That’d be quite useful!
No, since -x means to “disregard standard ignore rules”, such as .gitignore and .git/info/exclude.

> Don’t use the standard ignore rules (see gitignore[5]), but still use the ignore rules given with -e options from the command line.