secrets.yml/credentials.yml.enc automatically in .gitignore

Hi all,

I’m new so please forgive me if this has been brought up before, but I noticed that rails new generates a .gitignore, but secrets.yml is not automatically added to it. I found this confusing and fortunately didn’t add anything sensitive before I pushed my code up to git, but easily could have done so as a newcomer.

I see that credentials.yml.enc is coming in 5.2 and don’t know if that changes the situation or not, but if not, it’s something I propose as a change.

Would be interested to hear thoughts on why this isn’t done be default already.


Hey Jennifer,


That confusing aspect of secrets.yml is exactly why we added credentials. See the motivation up top here: