Method: Vagrant::BoxCollection#reload!

Defined in:
lib/vagrant/box_collection.rb

#reload!Object

Loads the list of all boxes from the source. This modifies the current array.



46
47
48
49
50
51
52
53
54
55
# File 'lib/vagrant/box_collection.rb', line 46

def reload!
  @boxes.clear

  Dir.open(@directory) do |dir|
    dir.each do |d|
      next if d == "." || d == ".." || !@directory.join(d).directory?
      @boxes << Box.new(d, @directory.join(d), @action_runner)
    end
  end
end