aboutsummaryrefslogtreecommitdiffstats
path: root/lib/bundler/lazy_specification.rb
diff options
context:
space:
mode:
authorCarl Lerche <carllerche@mac.com>2010-06-05 14:03:33 -0700
committerCarl Lerche <carllerche@mac.com>2010-06-05 14:03:33 -0700
commit91dcd2ce5d0844220741dff4789aedde363f652a (patch)
tree978a6117ebfab6f6810afc9820c24fd8b485299c /lib/bundler/lazy_specification.rb
parent07b7b0326fa33e1c8ca1533e64571b1a282b0e63 (diff)
downloadbundler-91dcd2ce5d0844220741dff4789aedde363f652a.tar.gz
Fix some platform related bugs
Diffstat (limited to 'lib/bundler/lazy_specification.rb')
-rw-r--r--lib/bundler/lazy_specification.rb8
1 files changed, 2 insertions, 6 deletions
diff --git a/lib/bundler/lazy_specification.rb b/lib/bundler/lazy_specification.rb
index b8800e5d..d4367db4 100644
--- a/lib/bundler/lazy_specification.rb
+++ b/lib/bundler/lazy_specification.rb
@@ -3,6 +3,8 @@ require "rubygems/spec_fetcher"
module Bundler
class LazySpecification
+ include Gem::MatchPlatform
+
attr_reader :name, :version, :dependencies, :platform
attr_accessor :source
@@ -27,12 +29,6 @@ module Bundler
@name == dependency.name && dependency.requirement.satisfied_by?(Gem::Version.new(@version))
end
- def match_platform(p)
- platform.nil? or p == platform or
- (p != Gem::Platform::RUBY and p =~ platform) or
- (p == Gem::Platform::RUBY and platform.to_generic == Gem::Platform::RUBY)
- end
-
def to_lock
if platform == Gem::Platform::RUBY or platform.nil?
out = " #{name} (#{version})\n"