lib/classmate/config.rb
# A shortcut to access default configuration stored in RAILS_ROOT/config/classmate.yml
A shortcut to access default configuration stored in RAILS_ROOT/config/classmate.yml
A shortcut to access default configuration stored in RAILS_ROOT / config / classmate . yml
def load_default_config_from_file
        config_data = YAML.load(
          ERB.new(
            File.read(::Rails.root.join("config", "classmate.yml"))
          ).result
        )[::Rails.env]
        raise NotConfigured.new("Unable to load configuration for #{ ::Rails.env } from config/classmate.yml") unless config_data
        config_data
      end
def load_default_config_from_file config_data = YAML . load ( ERB . new ( File . read ( :: Rails . root . join ( "config" , "classmate.yml" ) ) ) . result ) [ :: Rails . env ] raise NotConfigured . new ( "Unable to load configuration for #{ ::Rails.env } from config/classmate.yml" ) unless config_data config_data end
A shortcut to access default configuration stored in RAILS_ROOT/config/classmate.yml
A shortcut to access default configuration stored in RAILS_ROOT / config / classmate . yml