Hosts to V2

This commit is contained in:
Mitchell Hashimoto 2012-11-06 21:20:22 -08:00
parent 02e499da47
commit 5a33b7ee54
12 changed files with 13 additions and 13 deletions

View File

@ -191,14 +191,14 @@ module Vagrant
# will return nil, and we don't want to trigger a detect load.
host_klass = config.global.vagrant.host
if host_klass.nil? || host_klass == :detect
hosts = Vagrant.plugin("1").manager.hosts
hosts = Vagrant.plugin("2").manager.hosts
# Get the flattened list of available hosts
host_klass = Hosts.detect(hosts)
end
# If no host class is detected, we use the base class.
host_klass ||= Vagrant.plugin("1", :host)
host_klass ||= Vagrant.plugin("2", :host)
@host ||= host_klass.new(@ui)
end

View File

@ -2,7 +2,7 @@ require "vagrant"
module VagrantPlugins
module HostArch
class Plugin < Vagrant.plugin("1")
class Plugin < Vagrant.plugin("2")
name "Arch host"
description "Arch host support."

View File

@ -6,7 +6,7 @@ require 'vagrant/util/platform'
module VagrantPlugins
module HostBSD
# Represents a BSD host, such as FreeBSD and Darwin (Mac OS X).
class Host < Vagrant.plugin("1", :host)
class Host < Vagrant.plugin("2", :host)
include Vagrant::Util
include Vagrant::Util::Retryable

View File

@ -2,7 +2,7 @@ require "vagrant"
module VagrantPlugins
module HostBSD
class Plugin < Vagrant.plugin("1")
class Plugin < Vagrant.plugin("2")
name "BSD host"
description "BSD host support."

View File

@ -2,7 +2,7 @@ require "vagrant"
module VagrantPlugins
module HostFedora
class Plugin < Vagrant.plugin("1")
class Plugin < Vagrant.plugin("2")
name "Fedora host"
description "Fedora host support."

View File

@ -2,7 +2,7 @@ require "vagrant"
module VagrantPlugins
module HostFreeBSD
class Plugin < Vagrant.plugin("1")
class Plugin < Vagrant.plugin("2")
name "FreeBSD host"
description "FreeBSD host support."

View File

@ -2,7 +2,7 @@ require "vagrant"
module VagrantPlugins
module HostGentoo
class Plugin < Vagrant.plugin("1")
class Plugin < Vagrant.plugin("2")
name "Gentoo host"
description "Gentoo host support."

View File

@ -6,7 +6,7 @@ require 'vagrant/util/platform'
module VagrantPlugins
module HostLinux
# Represents a Linux based host, such as Ubuntu.
class Host < Vagrant.plugin("1", :host)
class Host < Vagrant.plugin("2", :host)
include Vagrant::Util
include Vagrant::Util::Retryable

View File

@ -2,7 +2,7 @@ require "vagrant"
module VagrantPlugins
module HostLinux
class Plugin < Vagrant.plugin("1")
class Plugin < Vagrant.plugin("2")
name "Linux host"
description "Linux host support."

View File

@ -2,7 +2,7 @@ require "vagrant"
module VagrantPlugins
module HostOpenSUSE
class Plugin < Vagrant.plugin("1")
class Plugin < Vagrant.plugin("2")
name "OpenSUSE host"
description "OpenSUSE host support."

View File

@ -3,7 +3,7 @@ require 'vagrant/util/platform'
module VagrantPlugins
module HostWindows
class Host < Vagrant.plugin("1", :host)
class Host < Vagrant.plugin("2", :host)
def self.match?
Vagrant::Util::Platform.windows?
end

View File

@ -2,7 +2,7 @@ require "vagrant"
module VagrantPlugins
module HostWindows
class Plugin < Vagrant.plugin("1")
class Plugin < Vagrant.plugin("2")
name "Windows host"
description "Windows host support."