Sha256: f5a2171dd8e73b1d02fc90bb57a188663121a26bb0661ee8f5a7aa7740d96257

Contents?: true

Size: 530 Bytes

Versions: 7

Compression:

Stored size: 530 Bytes

Contents

module Wikidata
  class Config
    class << self
      attr_accessor :options, :faraday, :settings, :mapping

      def configure &block
        yield self
      end
    end

    @options = {}
    @faraday = -> (builder) { builder.adapter :excon }
    @settings = Hashie::Mash.new(
      YAML.load_file(
        File.expand_path('../../../config/settings.yml', __FILE__)
      )
    )
    @mapping = Hashie::Mash.new(
      YAML.load_file(
        File.expand_path('../../../config/mapping.yml', __FILE__)
      )
    )
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
wikidata-client-0.0.10 lib/wikidata/config.rb
wikidata-client-0.0.9 lib/wikidata/config.rb
wikidata-client-0.0.8 lib/wikidata/config.rb
wikidata-client-0.0.7 lib/wikidata/config.rb
wikidata-client-0.0.6 lib/wikidata/config.rb
wikidata-client-0.0.5 lib/wikidata/config.rb
wikidata-client-0.0.4 lib/wikidata/config.rb