A lot of programs and tools will try to be cute and write into your bash files for you. I was mostly waxing philosophical at that point having gotten nerd sniped by "write a gui tool for environment variables" and "environment variables like $PATH in bash files" coming together in my head.
What's wrong with an envfile or envdir? The envdir is kind of annoying but at least you can set permissions on the files inside it.