class Vagrant::Bundler::BuiltinSet
This is a custom Gem::Resolver::Set for use with vagrant “system” gems. It allows the installed set of gems to be used for providing a solution while enforcing strict constraints. This ensures that plugins cannot “upgrade” gems that are builtin to vagrant itself.
Public Class Methods
new()
click to toggle source
Calls superclass method
# File lib/vagrant/bundler.rb, line 799 def initialize super @remote = false @specs = [] end
Public Instance Methods
add_builtin_spec(spec)
click to toggle source
# File lib/vagrant/bundler.rb, line 805 def add_builtin_spec(spec) @specs.push(spec).uniq! end
find_all(req)
click to toggle source
# File lib/vagrant/bundler.rb, line 809 def find_all(req) @specs.select do |spec| allow_prerelease = spec.name == "vagrant" && Vagrant.prerelease? req.match?(spec, allow_prerelease) end.map do |spec| Gem::Resolver::InstalledSpecification.new(self, spec) end end