Sha256: 154a8bcec5f24060e4fc1d9823aed62ef001d837b69f3839f6610f606d89ba88

Contents?: true

Size: 802 Bytes

Versions: 1

Compression:

Stored size: 802 Bytes

Contents

require "pipekit/configurable"
require "httparty"
require "pipekit/version"
require "pipekit/request"
require "pipekit/repository"
require "pipekit/person"
require "pipekit/deal"
require "pipekit/person_field"
require "pipekit/note"

module Pipekit
  include Configurable

  # Define a path to Pipedrive config file
  #
  # Example:
  #
  # Pipekit.config_file_path = File.join("config", "pipedrive.yml")
  class << self
    attr_writer :config_file_path

    def config_file_path
      @config_file_path || raise_config_error
    end

    def raise_config_error
      raise ConfigNotSetError, "You need to create a yaml file with your Pipedrive config and set the path to the file using `Pipedrive.config_file_path = 'path/to/file.yml'`"
    end
  end

  ConfigNotSetError = Class.new(Exception)
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
pipekit-0.2.0 lib/pipekit.rb