Whitespace
This commit is contained in:
parent
debe50957b
commit
7b03bf335b
|
@ -7,7 +7,7 @@ module VagrantPlugins
|
||||||
module Action
|
module Action
|
||||||
class Import
|
class Import
|
||||||
def initialize(app, env)
|
def initialize(app, env)
|
||||||
@app = app
|
@app = app
|
||||||
@logger = Log4r::Logger.new("vagrant::hyperv::import")
|
@logger = Log4r::Logger.new("vagrant::hyperv::import")
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -64,7 +64,7 @@ module VagrantPlugins
|
||||||
if %w{.vhd .vhdx}.include?(f.extname.downcase)
|
if %w{.vhd .vhdx}.include?(f.extname.downcase)
|
||||||
image_path = f
|
image_path = f
|
||||||
image_ext = f.extname.downcase
|
image_ext = f.extname.downcase
|
||||||
image_filename = File.basename(f,image_ext)
|
image_filename = File.basename(f, image_ext)
|
||||||
break
|
break
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
@ -114,8 +114,8 @@ module VagrantPlugins
|
||||||
end
|
end
|
||||||
|
|
||||||
env[:ui].detail("Cloning virtual hard drive...")
|
env[:ui].detail("Cloning virtual hard drive...")
|
||||||
source_path = image_path.to_s
|
source_path = image_path.to_s
|
||||||
dest_path = env[:machine].data_dir.join("#{image_filename}#{image_ext}").to_s
|
dest_path = env[:machine].data_dir.join("#{image_filename}#{image_ext}").to_s
|
||||||
|
|
||||||
# Still hard copy the disk of old XML configurations
|
# Still hard copy the disk of old XML configurations
|
||||||
if config_type == 'xml'
|
if config_type == 'xml'
|
||||||
|
@ -130,11 +130,11 @@ module VagrantPlugins
|
||||||
# We have to normalize the paths to be Windows paths since
|
# We have to normalize the paths to be Windows paths since
|
||||||
# we're executing PowerShell.
|
# we're executing PowerShell.
|
||||||
options = {
|
options = {
|
||||||
vm_config_file: config_path.to_s.gsub("/", "\\"),
|
vm_config_file: config_path.to_s.gsub("/", "\\"),
|
||||||
vm_config_type: config_type,
|
vm_config_type: config_type,
|
||||||
source_path: source_path.to_s,
|
source_path: source_path.to_s,
|
||||||
dest_path: env[:machine].data_dir.join("Virtual Hard Disks").join("#{image_filename}#{image_ext}").to_s,
|
dest_path: env[:machine].data_dir.join("Virtual Hard Disks").join("#{image_filename}#{image_ext}").to_s,
|
||||||
data_path: env[:machine].data_dir.to_s.gsub("/", "\\")
|
data_path: env[:machine].data_dir.to_s.gsub("/", "\\")
|
||||||
}
|
}
|
||||||
options[:switchname] = switch if switch
|
options[:switchname] = switch if switch
|
||||||
options[:memory] = memory if memory
|
options[:memory] = memory if memory
|
||||||
|
|
Loading…
Reference in New Issue