Define your environment-specific settings as YAML files, then access them easily via the Settings
class inside your RubyMotion application.
Add this line to your application's Gemfile:
gem 'motion-environment-settings'
And then execute:
$ bundle
Create a YAML file of the settings you want configured by environment.
Example:
development.yml
api_host: http://localhost
production.yml
api_host: http://productionurl
By default, motion-environment-settings
will look for these files in your/app/root/config/environments
. You can customize this path by setting
Motion::EnvironmentSettings.config_path = "your/custom/path"
in your Rakefile.
- 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