[lxc] go fmt our files

This commit is contained in:
Chris Lundquist 2016-05-25 19:34:51 +00:00 committed by Megan Marsh
parent 9b4a7e935f
commit 5eb1bc9338
6 changed files with 20 additions and 21 deletions

View File

@ -27,7 +27,7 @@ func (a *Artifact) String() string {
}
func (a *Artifact) State(name string) interface{} {
return nil
return nil
}
func (a *Artifact) Destroy() error {

View File

@ -1,8 +1,8 @@
package lxc
import (
"testing"
"os"
"testing"
"github.com/mitchellh/packer/packer"
)

View File

@ -1,14 +1,14 @@
package lxc
import (
"github.com/mitchellh/packer/packer"
"testing"
"github.com/mitchellh/packer/packer"
"testing"
)
func TestCommunicator_ImplementsCommunicator(t *testing.T) {
var raw interface{}
raw = &LxcAttachCommunicator{}
if _, ok := raw.(packer.Communicator); !ok {
t.Fatalf("Communicator should be a communicator")
}
var raw interface{}
raw = &LxcAttachCommunicator{}
if _, ok := raw.(packer.Communicator); !ok {
t.Fatalf("Communicator should be a communicator")
}
}

View File

@ -7,8 +7,8 @@ import (
"github.com/mitchellh/packer/helper/config"
"github.com/mitchellh/packer/packer"
"github.com/mitchellh/packer/template/interpolate"
"time"
"os"
"time"
)
type Config struct {

View File

@ -1,16 +1,16 @@
package lxc
import (
"github.com/mitchellh/multistep"
"fmt"
"github.com/mitchellh/packer/packer"
"bytes"
"os/exec"
"log"
"strings"
"path/filepath"
"os"
"fmt"
"github.com/mitchellh/multistep"
"github.com/mitchellh/packer/packer"
"io"
"log"
"os"
"os/exec"
"path/filepath"
"strings"
)
type stepExport struct{}
@ -75,7 +75,6 @@ func (s *stepExport) Run(state multistep.StateBag) multistep.StepAction {
func (s *stepExport) Cleanup(state multistep.StateBag) {}
func (s *stepExport) SudoCommand(args ...string) error {
var stdout, stderr bytes.Buffer
@ -96,4 +95,4 @@ func (s *stepExport) SudoCommand(args ...string) error {
log.Printf("stderr: %s", stderrString)
return err
}
}

View File

@ -7,7 +7,7 @@ import (
)
// StepProvision provisions the instance within a chroot.
type StepProvision struct {}
type StepProvision struct{}
func (s *StepProvision) Run(state multistep.StateBag) multistep.StepAction {
hook := state.Get("hook").(packer.Hook)