Sha256: a6ee8ca77a5fab7f4746d4d70c7858d7311a29428421b67ef9f1e854d18a8105

Contents?: true

Size: 162 Bytes

Versions: 171

Compression:

Stored size: 162 Bytes

Contents

module Tins
  module RequireMaybe
    def require_maybe(library)
      require library
    rescue LoadError => e
      block_given? and yield e
    end
  end
end

Version data entries

171 entries across 153 versions & 9 rubygems

Version Path
tins-1.8.0 lib/tins/require_maybe.rb
tins-1.7.0 lib/tins/require_maybe.rb
suzuko-0.1.8 vendor/bundle/ruby/2.0.0/gems/tins-1.6.0/lib/tins/require_maybe.rb
suzuko-0.1.7 vendor/bundle/ruby/2.0.0/gems/tins-1.6.0/lib/tins/require_maybe.rb
mastermind_adeybee-0.1.4 vendor/bundle/ruby/2.2.0/gems/tins-1.6.0/lib/tins/require_maybe.rb
mastermind_adeybee-0.1.3 vendor/bundle/ruby/2.2.0/gems/tins-1.6.0/lib/tins/require_maybe.rb
mastermind_adeybee-0.1.2 vendor/bundle/ruby/2.2.0/gems/tins-1.6.0/lib/tins/require_maybe.rb
mastermind_adeybee-0.1.1 vendor/bundle/ruby/2.2.0/gems/tins-1.6.0/lib/tins/require_maybe.rb
vagrant-cloudstack-1.2.0 vendor/bundle/gems/tins-1.6.0/lib/tins/require_maybe.rb
tins-1.6.0 lib/tins/require_maybe.rb
tins-1.5.4 lib/tins/require_maybe.rb
tins-1.5.3 lib/tins/require_maybe.rb
vagrant-cloudstack-1.1.0 vendor/bundle/gems/tins-1.5.1/lib/tins/require_maybe.rb
vagrant-cloudstack-1.1.0 vendor/bundle/gems/tins-1.5.2/lib/tins/require_maybe.rb
tins-1.5.2 lib/tins/require_maybe.rb
tins-1.5.1 lib/tins/require_maybe.rb
tins-1.5.0 lib/tins/require_maybe.rb
tins-1.4.2 lib/tins/require_maybe.rb
tins-1.4.1 lib/tins/require_maybe.rb
tins-1.4.0 lib/tins/require_maybe.rb