Sha256: 9bdcfc49d07d719099e32d3dd9ec622f277dda3397c4631071ea0e0646391285

Contents?: true

Size: 401 Bytes

Versions: 1

Compression:

Stored size: 401 Bytes

Contents

require 'active_support'
require 'dotenv'

module Gris
  class << self
    def load_environment
      env_file = Gris.env.test? ? '.env.test' : '.env'
      Dotenv.overload env_file
    end

    def env
      @_env ||= ActiveSupport::StringInquirer.new(ENV['RACK_ENV'] || 'development')
    end

    def env=(environment)
      @_env = ActiveSupport::StringInquirer.new(environment)
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
gris-0.1.5 lib/gris/setup.rb