3 ms·
I usually make sure my .env files are in my .gitignore, but honestly its just my memory that prevents me from slipping up one day. Is there an automated strate
by gentleman11 7y ago
I usually make sure my .env files are in my .gitignore, but honestly its just my memory that prevents me from slipping up one day.
Is there an automated strategy that protects against slipups like this?
- enitihas 7y agoUse 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.
- throwaway8941 7y agoPut them into your global .gitignore echo -e >>~/.config/git/config '[core]\n excludesFile = ~/.config/git/gitignore' echo >>~/.config/git/gitignore '.env'
- makison 7y agoLaravel should/does have it on ignore by default.