From 2b35873dd9c83ef5fe327ccabc35a1107ff5d74d Mon Sep 17 00:00:00 2001 From: Thomas Dreibholz Date: Sat, 20 Feb 2021 20:31:09 +0100 Subject: [PATCH] Formatting fix. --- builder/virtualbox/iso/builder.go | 2 +- builder/virtualbox/iso/step_create_vm.go | 20 ++++++++++---------- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/builder/virtualbox/iso/builder.go b/builder/virtualbox/iso/builder.go index 53d1532c7..c82c435e0 100644 --- a/builder/virtualbox/iso/builder.go +++ b/builder/virtualbox/iso/builder.go @@ -224,7 +224,7 @@ func (b *Builder) Prepare(raws ...interface{}) ([]string, []string, error) { b.config.NICType = "82540EM" } switch b.config.NICType { - case "82540EM", "82543GC", "82545EM", "Am79C970A", "Am79C973", "Am79C960", "virtio": + case "82540EM", "82543GC", "82545EM", "Am79C970A", "Am79C973", "Am79C960", "virtio": // do nothing default: errs = packersdk.MultiErrorAppend( diff --git a/builder/virtualbox/iso/step_create_vm.go b/builder/virtualbox/iso/step_create_vm.go index 32895e713..bcef33a64 100644 --- a/builder/virtualbox/iso/step_create_vm.go +++ b/builder/virtualbox/iso/step_create_vm.go @@ -41,24 +41,24 @@ func (s *stepCreateVM) Run(ctx context.Context, state multistep.StateBag) multis if strings.ToLower(config.HWConfig.Sound) == "none" { commands[5] = []string{"modifyvm", name, "--audio", config.HWConfig.Sound, - "--audiocontroller", config.AudioController} + "--audiocontroller", config.AudioController} } else { commands[5] = []string{"modifyvm", name, "--audio", config.HWConfig.Sound, "--audioin", "on", "--audioout", "on", - "--audiocontroller", config.AudioController} + "--audiocontroller", config.AudioController} } commands[6] = []string{"modifyvm", name, "--chipset", config.Chipset} commands[7] = []string{"modifyvm", name, "--firmware", config.Firmware} // Set the configured NIC type for all 8 possible NICs commands[8] = []string{"modifyvm", name, - "--nictype1", config.NICType, - "--nictype2", config.NICType, - "--nictype3", config.NICType, - "--nictype4", config.NICType, - "--nictype5", config.NICType, - "--nictype6", config.NICType, - "--nictype7", config.NICType, - "--nictype8", config.NICType} + "--nictype1", config.NICType, + "--nictype2", config.NICType, + "--nictype3", config.NICType, + "--nictype4", config.NICType, + "--nictype5", config.NICType, + "--nictype6", config.NICType, + "--nictype7", config.NICType, + "--nictype8", config.NICType} commands[9] = []string{"modifyvm", name, "--graphicscontroller", config.GfxController} ui.Say("Creating virtual machine...")