From 3360c37fc713b89ec234fb75adc14d006b73265b Mon Sep 17 00:00:00 2001 From: Mitchell Hashimoto Date: Sat, 22 May 2010 00:33:57 -0700 Subject: [PATCH] Parallelize the commands. There are some issues with this but in general it works so far. More polish needs to be done. --- lib/vagrant/commands/base.rb | 7 ++++++- vagrant.gemspec | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/lib/vagrant/commands/base.rb b/lib/vagrant/commands/base.rb index d1b1db2a0..18f009b2d 100644 --- a/lib/vagrant/commands/base.rb +++ b/lib/vagrant/commands/base.rb @@ -105,9 +105,14 @@ module Vagrant if args[0] send(single_method, args[0]) else + threads = [] env.vms.keys.each do |name| - send(single_method, name) + threads << Thread.new do + send(single_method, name) + end end + + threads.each { |t| t.join } end end diff --git a/vagrant.gemspec b/vagrant.gemspec index 494ffa777..b5d1a011c 100644 --- a/vagrant.gemspec +++ b/vagrant.gemspec @@ -9,7 +9,7 @@ Gem::Specification.new do |s| s.required_rubygems_version = Gem::Requirement.new("> 1.3.1") if s.respond_to? :required_rubygems_version= s.authors = ["Mitchell Hashimoto", "John Bender"] - s.date = %q{2010-05-21} + s.date = %q{2010-05-22} s.default_executable = %q{vagrant} s.description = %q{Vagrant is a tool for building and distributing virtualized development environments.} s.email = ["mitchell.hashimoto@gmail.com", "john.m.bender@gmail.com"]