[lxc-devel] [distrobuilder/master] *: Fix imports
monstermunchkin on Github
lxc-bot at linuxcontainers.org
Tue Mar 6 10:18:26 UTC 2018
A non-text attachment was scrubbed...
Name: not available
Type: text/x-mailbox
Size: 363 bytes
Desc: not available
URL: <http://lists.linuxcontainers.org/pipermail/lxc-devel/attachments/20180306/7b04c07d/attachment.bin>
-------------- next part --------------
From 3530b9b87d4bc74d3eb187f1dcf48d4c9ef958f9 Mon Sep 17 00:00:00 2001
From: Thomas Hipp <thomas.hipp at canonical.com>
Date: Tue, 6 Mar 2018 11:16:22 +0100
Subject: [PATCH] *: Fix imports
Signed-off-by: Thomas Hipp <thomas.hipp at canonical.com>
---
generators/generators.go | 4 ++--
generators/hostname.go | 3 ++-
image/image.go | 2 +-
image/lxc.go | 2 +-
image/lxd.go | 7 ++++---
image/lxd_test.go | 3 ++-
sources/alpine-http.go | 3 ++-
sources/archlinux-http.go | 3 ++-
sources/ubuntu-http.go | 3 ++-
9 files changed, 18 insertions(+), 12 deletions(-)
diff --git a/generators/generators.go b/generators/generators.go
index d7cf7b3..19c55dd 100644
--- a/generators/generators.go
+++ b/generators/generators.go
@@ -2,13 +2,13 @@ package generators
import (
"os"
+ p "path"
"path/filepath"
"strings"
- p "path"
+ "github.com/lxc/lxd/shared"
"github.com/lxc/distrobuilder/image"
- "github.com/lxc/lxd/shared"
)
// Generator interface.
diff --git a/generators/hostname.go b/generators/hostname.go
index 6ae6a0a..f0b1206 100644
--- a/generators/hostname.go
+++ b/generators/hostname.go
@@ -5,8 +5,9 @@ import (
"os"
"path/filepath"
- "github.com/lxc/distrobuilder/image"
"github.com/lxc/lxd/shared/api"
+
+ "github.com/lxc/distrobuilder/image"
)
// HostnameGenerator represents the Hostname generator.
diff --git a/image/image.go b/image/image.go
index a1be0aa..3c15761 100644
--- a/image/image.go
+++ b/image/image.go
@@ -1,6 +1,6 @@
package image
-import pongo2 "gopkg.in/flosch/pongo2.v3"
+import "gopkg.in/flosch/pongo2.v3"
func renderTemplate(template string, ctx pongo2.Context) (string, error) {
var (
diff --git a/image/lxc.go b/image/lxc.go
index 64d0ceb..85e0e9a 100644
--- a/image/lxc.go
+++ b/image/lxc.go
@@ -8,7 +8,7 @@ import (
"time"
lxd "github.com/lxc/lxd/shared"
- pongo2 "gopkg.in/flosch/pongo2.v3"
+ "gopkg.in/flosch/pongo2.v3"
"github.com/lxc/distrobuilder/shared"
)
diff --git a/image/lxd.go b/image/lxd.go
index f04b6c6..a4750ff 100644
--- a/image/lxd.go
+++ b/image/lxd.go
@@ -6,11 +6,12 @@ import (
"path/filepath"
"time"
- "github.com/lxc/distrobuilder/shared"
"github.com/lxc/lxd/shared/api"
"github.com/lxc/lxd/shared/osarch"
- pongo2 "gopkg.in/flosch/pongo2.v3"
- yaml "gopkg.in/yaml.v2"
+ "gopkg.in/flosch/pongo2.v3"
+ "gopkg.in/yaml.v2"
+
+ "github.com/lxc/distrobuilder/shared"
)
// A LXDImage represents a LXD image.
diff --git a/image/lxd_test.go b/image/lxd_test.go
index a855de1..09fc323 100644
--- a/image/lxd_test.go
+++ b/image/lxd_test.go
@@ -10,8 +10,9 @@ import (
"testing"
"time"
- "github.com/lxc/distrobuilder/shared"
lxd "github.com/lxc/lxd/shared"
+
+ "github.com/lxc/distrobuilder/shared"
)
var lxdImageDef = shared.DefinitionImage{
diff --git a/sources/alpine-http.go b/sources/alpine-http.go
index 19f1155..17ffb4b 100644
--- a/sources/alpine-http.go
+++ b/sources/alpine-http.go
@@ -7,8 +7,9 @@ import (
"path/filepath"
"strings"
- "github.com/lxc/distrobuilder/shared"
lxd "github.com/lxc/lxd/shared"
+
+ "github.com/lxc/distrobuilder/shared"
)
// AlpineLinuxHTTP represents the Alpine Linux downloader.
diff --git a/sources/archlinux-http.go b/sources/archlinux-http.go
index ef22d3d..b6b491d 100644
--- a/sources/archlinux-http.go
+++ b/sources/archlinux-http.go
@@ -6,8 +6,9 @@ import (
"os"
"path/filepath"
- "github.com/lxc/distrobuilder/shared"
lxd "github.com/lxc/lxd/shared"
+
+ "github.com/lxc/distrobuilder/shared"
)
// ArchLinuxHTTP represents the Arch Linux downloader.
diff --git a/sources/ubuntu-http.go b/sources/ubuntu-http.go
index 7554912..fcc5d4b 100644
--- a/sources/ubuntu-http.go
+++ b/sources/ubuntu-http.go
@@ -10,8 +10,9 @@ import (
"regexp"
"strings"
- "github.com/lxc/distrobuilder/shared"
lxd "github.com/lxc/lxd/shared"
+
+ "github.com/lxc/distrobuilder/shared"
)
// UbuntuHTTP represents the Ubuntu HTTP downloader.
More information about the lxc-devel
mailing list