Rename EasyCommand namespace to Easy

This commit is contained in:
Mitchell Hashimoto 2012-05-05 22:16:13 -07:00
parent 3d147f1d96
commit 31ac7271aa
5 changed files with 11 additions and 11 deletions

View File

@ -66,7 +66,7 @@ module Vagrant
autoload :DataStore, 'vagrant/data_store'
autoload :Downloaders, 'vagrant/downloaders'
autoload :Driver, 'vagrant/driver'
autoload :EasyCommand, 'vagrant/easy_command'
autoload :Easy, 'vagrant/easy'
autoload :Environment, 'vagrant/environment'
autoload :Errors, 'vagrant/errors'
autoload :Guest, 'vagrant/guest'

View File

@ -1,14 +1,14 @@
module Vagrant
module EasyCommand
autoload :Base, "vagrant/easy_command/base"
autoload :Operations, "vagrant/easy_command/operations"
module Easy
autoload :CommandBase, "vagrant/easy/command_base"
autoload :Operations, "vagrant/easy/operations"
# This creates a new easy command. This typically is not called
# directly. Instead, the plugin interface's `easy_command` is
# used to create one of these.
def self.create(name, &block)
def self.create_command(name, &block)
# Create a new command class for this command, and return it
command = Class.new(Base)
command = Class.new(CommandBase)
command.configure(name, &block)
command
end

View File

@ -1,10 +1,10 @@
require "log4r"
module Vagrant
module EasyCommand
module Easy
# Base class for all easy commands. This contains the basic code
# that knows how to run the easy commands.
class Base < Vagrant::Command::Base
class CommandBase < Vagrant::Command::Base
@@command = nil
@@runner = nil

View File

@ -6,13 +6,13 @@ require "log4r"
require "vagrant/util/subprocess"
module Vagrant
module EasyCommand
module Easy
# This class contains all the "operations" that easy commands are able
# to run. An instance of this is class is what is sent into the callback
# for all easy commands.
class Operations
def initialize(vm)
@logger = Log4r::Logger.new("vagrant::easy_command::operations")
@logger = Log4r::Logger.new("vagrant::easy::operations")
@vm = vm
end

View File

@ -113,7 +113,7 @@ module Vagrant
# @param [String] name Name of the command, how it will be invoked
# on the command line.
def self.easy_command(name, &block)
command(name) { EasyCommand.create(name, &block) }
command(name) { Easy.create_command(name, &block) }
end
# Defines an additionally available guest implementation with