Re:Ask HN: My web app was hacked today – Bad experiences and...
by enitihas on Thursday February 27, 2020 @01:26AM
(#22431089)
Use a git template for .git/info/exclude. This will make sure that every new repo you create or clone will have by default exclude list. Git templates can be used for other stuff too. I use them for having a pre-push hook to run a clean build.
Re:Ask HN: My web app was hacked today – Bad experiences and...
by throwaway8941 on Thursday February 27, 2020 @06:29AM
(#22432362)
Put them into your global .gitignore
echo -e >>~/.config/git/config '[core]\n excludesFile = ~/.config/git/gitignore'
echo >>~/.config/git/gitignore '.env'
Is there an automated strategy that protects against slipups like this?