Advertisement
Guest User

Untitled

a guest
Mar 26th, 2017
60
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.82 KB | None | 0 0
  1. require_relative 'boot'
  2. require 'csv'
  3. require 'rails/all'
  4.  
  5. # Require the gems listed in Gemfile, including any gems
  6. # you've limited to :test, :development, or :production.
  7. Bundler.require(*Rails.groups)
  8.  
  9. module Giant
  10. class Application < Rails::Application
  11. # Settings in config/environments/* take precedence over those specified here.
  12. # Application configuration should go into files in config/initializers
  13. # -- all .rb files in that directory are automatically loaded.
  14. config.time_zone = 'Beijing'
  15. config.active_record.default_timezone = :local
  16.  
  17. WillPaginate.per_page = 15
  18.  
  19. config.before_configuration do
  20. env_file = File.join(Rails.root, 'config', 'env.yml')
  21. YAML.load(File.open(env_file)).each do |key, value|
  22. ENV[key.to_s] = value
  23. end if File.exists?(env_file)
  24. end
  25. end
  26. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement