2010-08-24 04:41:40 +00:00
|
|
|
require 'json'
|
|
|
|
require 'virtualbox'
|
2010-08-24 18:18:29 +00:00
|
|
|
require 'vagrant/errors'
|
|
|
|
require 'vagrant/util/glob_loader'
|
2010-03-13 11:08:26 +00:00
|
|
|
|
2010-08-24 04:33:14 +00:00
|
|
|
module Vagrant
|
2010-08-24 17:27:36 +00:00
|
|
|
# TODO: Move more classes over to the autoload model. We'll
|
|
|
|
# start small, but slowly move everything over.
|
|
|
|
|
|
|
|
autoload :CLI, 'vagrant/cli'
|
|
|
|
|
|
|
|
module Command
|
2010-08-24 17:58:36 +00:00
|
|
|
autoload :Base, 'vagrant/command/base'
|
|
|
|
autoload :GroupBase, 'vagrant/command/group_base'
|
2010-08-25 00:49:22 +00:00
|
|
|
autoload :Helpers, 'vagrant/command/helpers'
|
2010-08-25 06:50:20 +00:00
|
|
|
autoload :NamedBase, 'vagrant/command/named_base'
|
2010-08-24 17:27:36 +00:00
|
|
|
end
|
|
|
|
|
2010-08-24 18:18:29 +00:00
|
|
|
# The source root is the path to the root directory of
|
|
|
|
# the Vagrant gem.
|
|
|
|
def self.source_root
|
|
|
|
@source_root ||= File.expand_path('../../', __FILE__)
|
2010-08-24 04:33:14 +00:00
|
|
|
end
|
|
|
|
end
|
|
|
|
|
2010-08-24 04:41:40 +00:00
|
|
|
# Load them up. One day we'll convert this to autoloads. Today
|
|
|
|
# is not that day. Low hanging fruit for anyone wishing to do it.
|
2010-08-24 04:33:14 +00:00
|
|
|
libdir = File.expand_path("lib/vagrant", Vagrant.source_root)
|
2010-08-24 17:27:36 +00:00
|
|
|
Vagrant::GlobLoader.glob_require(libdir, %w{util util/stacked_proc_runner
|
2010-07-09 04:52:56 +00:00
|
|
|
downloaders/base config provisioners/base provisioners/chef systems/base
|
2010-08-24 16:19:16 +00:00
|
|
|
action/exception_catcher hosts/base})
|
2010-07-04 02:58:03 +00:00
|
|
|
|
|
|
|
# Initialize the built-in actions
|
|
|
|
Vagrant::Action.builtin!
|