Sha256: 01a708ea2087b19a7697d9c45e9ee1e1372fe27e4156a64a60b5a142be96ac30

Contents?: true

Size: 1.08 KB

Versions: 26

Compression:

Stored size: 1.08 KB

Contents

# name spaces reservation
module TDiary; end
module TDiary::Cache; end

# Set up gems listed in the Gemfile.
ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../../Gemfile', __FILE__)

require 'bundler/setup' if File.exist?(ENV['BUNDLE_GEMFILE'])

# FIXME: workaround fix for tainted path from Gemfile.local
$LOAD_PATH.each{|lp| $LOAD_PATH << $LOAD_PATH.shift.dup}

if defined?(Bundler)
  env = [:default, :rack]
  env << :development if ENV['RACK_ENV'].nil? || ENV['RACK_ENV'].empty?
  env << ENV['RACK_ENV'].intern if ENV['RACK_ENV']
  env = env.reject{|e|
	  (Bundler.settings.without rescue Bundler.settings[:without]).include? e
  }
  Bundler.require *env
end

# Bundler.require doesn't load gems specified in .gemspec
# see: https://github.com/bundler/bundler/issues/1041
#
# load gems dependented by tdiary
tdiary_spec = Bundler.definition.specs.find {|spec| spec.name == 'tdiary'}
if tdiary_spec
  tdiary_spec.dependent_specs.each {|dep_spec|
    begin
      require dep_spec.name
    rescue LoadError => e
      STDERR.puts "failed require '#{dep_spec.name}'"
      STDERR.puts e
    end
  }
end

Version data entries

26 entries across 21 versions & 1 rubygems

Version Path
tdiary-5.3.0 lib/tdiary/environment.rb
tdiary-5.2.4 lib/tdiary/environment.rb
tdiary-5.2.3 lib/tdiary/environment.rb
tdiary-5.2.2 lib/tdiary/environment.rb
tdiary-5.2.1 lib/tdiary/environment.rb
tdiary-5.2.0 lib/tdiary/environment.rb
tdiary-5.1.7 lib/tdiary/environment.rb
tdiary-5.1.6 vendor/bundle/ruby/2.7.0/gems/tdiary-5.1.5/lib/tdiary/environment.rb
tdiary-5.1.6 vendor/bundle/ruby/2.7.0/gems/tdiary-5.1.5/vendor/bundle/ruby/3.0.0/gems/tdiary-5.1.4/lib/tdiary/environment.rb
tdiary-5.1.6 lib/tdiary/environment.rb
tdiary-5.1.5 vendor/bundle/ruby/3.0.0/gems/tdiary-5.1.4/lib/tdiary/environment.rb
tdiary-5.1.5 lib/tdiary/environment.rb
tdiary-5.1.4 lib/tdiary/environment.rb
tdiary-5.1.3 lib/tdiary/environment.rb
tdiary-5.1.2 vendor/bundle/ruby/2.6.0/gems/tdiary-5.0.14/lib/tdiary/environment.rb
tdiary-5.1.2 lib/tdiary/environment.rb
tdiary-5.1.1 vendor/bundle/ruby/2.6.0/gems/tdiary-5.0.14/lib/tdiary/environment.rb
tdiary-5.1.1 lib/tdiary/environment.rb
tdiary-5.1.0 lib/tdiary/environment.rb
tdiary-5.0.14 lib/tdiary/environment.rb