Add a top_level.yml config file with the default constants. These values are inherited in every environments constant file. However, these are overridden by the values in the environments constant file.
As a result you you only need keep values in the environment constant file for those constants which need to be different from default values.
In the GlobalConstant file, call the method TopLevelConfig.get_environment_constants to get the overall environments constants.
Add this line to your application's Gemfile:
gem 'TopLevelConfig'
And then execute:
$ bundle
Or install it yourself as:
$ gem install TopLevelConfig
TODO: Write usage instructions here
- Fork it
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new Pull Request
#additional things
Has support for codacy checks