Reputation: 507
I've got two files: config.yml-sample and config.yml. The first one is being constantly updated, while the second is listed in .gitignore. When I add a line in config.yml-sample and push the commit, I want to have it duplicated in config.yml automatically on pull at other developers' workspaces.
How do I achieve this?
Upvotes: 0
Views: 96
Reputation: 467023
Another simple option is to have your application read config.yml.sample
on startup to find all the configuration keys (or whatever) that are mentioned there. Then after loading config.yml
you can see if any of those required keys are missing, and prompt the user to copy those lines in from config.yml.sample
, possibly customizing them when doing so.
Upvotes: 1