From 1b8f1a3864b318fccc5a77a0184a6f301bdc6153 Mon Sep 17 00:00:00 2001 From: Mitchell Hashimoto Date: Fri, 17 Jan 2014 20:34:25 -0800 Subject: [PATCH] core: convert more output to `output` method --- lib/vagrant/action/builtin/wait_for_communicator.rb | 4 ++-- lib/vagrant/plugin/v2/communicator.rb | 4 ++++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/lib/vagrant/action/builtin/wait_for_communicator.rb b/lib/vagrant/action/builtin/wait_for_communicator.rb index c30127659..c69784629 100644 --- a/lib/vagrant/action/builtin/wait_for_communicator.rb +++ b/lib/vagrant/action/builtin/wait_for_communicator.rb @@ -50,7 +50,7 @@ module Vagrant end # Wait for a result or an interrupt - env[:ui].info I18n.t("vagrant.boot_waiting") + env[:ui].output(I18n.t("vagrant.boot_waiting")) while ready_thr.alive? && states_thr.alive? sleep 1 return if env[:interrupted] @@ -72,7 +72,7 @@ module Vagrant raise Errors::VMBootTimeout end - env[:ui].info I18n.t("vagrant.boot_completed") + env[:ui].output(I18n.t("vagrant.boot_completed")) # Make sure our threads are all killed ready_thr.kill diff --git a/lib/vagrant/plugin/v2/communicator.rb b/lib/vagrant/plugin/v2/communicator.rb index 1ac8ef1bb..ebe704918 100644 --- a/lib/vagrant/plugin/v2/communicator.rb +++ b/lib/vagrant/plugin/v2/communicator.rb @@ -49,6 +49,10 @@ module Vagrant # wait_for_ready waits until the communicator is ready, blocking # until then. It will wait up to the given duration or raise an # exception if something goes wrong. + # + # @param [Fixnum] duration Timeout in seconds. + # @return [Boolean] Will return true on successful connection + # or false on timeout. def wait_for_ready(duration) # By default, we implement a naive solution. begin