The above Git command was necessitated after utilizing the Figaro gem to create environment variables for secure authentication. For additional questions or concerns, consult the Git Prune documentation.
If using Rails 4.1 or newer, secret keys should be created in config/secrets.yml, and set differently based on the environment. In this case, generate a random token and set it as
Presumably, the aforementioned effected, so include the application.yml and secrets.yml files in .gitignore. In my experience, an immediate commit, merge, and push to origin could include these files, which obviously defeats the purpose of authentication-so commit, merge to master, _but before pushing to origin_, consider the following, found on StackOverflow:
To untrack a single file that has already been added/initialized to your repository, i.e., stop tracking the file but not delete it from your system use:
To untrack every file that is now in your .gitignore:
First commit any outstanding code changes, and then, run this command:
This removes any changed files from the index(staging area), then just run: