From 19c2b77a8b18882390f5283bf554434e1148e54f Mon Sep 17 00:00:00 2001 From: Benji Visser Date: Thu, 8 Aug 2024 17:03:19 -0400 Subject: [PATCH] make format Signed-off-by: Benji Visser --- xeol/distro/distro.go | 3 +-- xeol/distro/distro_test.go | 6 +++--- xeol/pkg/package_test.go | 3 +-- xeol/pkg/provider.go | 3 +-- xeol/pkg/provider_test.go | 3 +-- xeol/pkg/purl_provider.go | 3 +-- xeol/pkg/syft_provider.go | 1 + xeol/pkg/syft_sbom_provider.go | 4 ++-- xeol/pkg/syft_sbom_provider_test.go | 7 +++---- xeol/pkg/upstream_package.go | 3 +-- xeol/pkg/upstream_package_test.go | 3 +-- 11 files changed, 16 insertions(+), 23 deletions(-) diff --git a/xeol/distro/distro.go b/xeol/distro/distro.go index 9f28e8c..a7249f9 100644 --- a/xeol/distro/distro.go +++ b/xeol/distro/distro.go @@ -4,9 +4,8 @@ import ( "fmt" "strings" - hashiVer "github.com/hashicorp/go-version" - "github.com/anchore/syft/syft/linux" + hashiVer "github.com/hashicorp/go-version" ) // Distro represents a Linux Distribution. diff --git a/xeol/distro/distro_test.go b/xeol/distro/distro_test.go index 6acf962..40b2c69 100644 --- a/xeol/distro/distro_test.go +++ b/xeol/distro/distro_test.go @@ -3,12 +3,12 @@ package distro import ( "testing" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" - "github.com/anchore/syft/syft/linux" "github.com/anchore/syft/syft/source" "github.com/anchore/syft/syft/source/directorysource" + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" + "github.com/xeol-io/xeol/internal/stringutil" ) diff --git a/xeol/pkg/package_test.go b/xeol/pkg/package_test.go index 3a310de..bce8be1 100644 --- a/xeol/pkg/package_test.go +++ b/xeol/pkg/package_test.go @@ -5,8 +5,6 @@ import ( "strings" "testing" - "github.com/stretchr/testify/assert" - "github.com/anchore/syft/syft/artifact" "github.com/anchore/syft/syft/cpe" "github.com/anchore/syft/syft/file" @@ -15,6 +13,7 @@ import ( syftPkg "github.com/anchore/syft/syft/pkg" "github.com/anchore/syft/syft/sbom" "github.com/anchore/syft/syft/testutil" + "github.com/stretchr/testify/assert" ) func TestNew(t *testing.T) { diff --git a/xeol/pkg/provider.go b/xeol/pkg/provider.go index 41f4cf6..2b06dff 100644 --- a/xeol/pkg/provider.go +++ b/xeol/pkg/provider.go @@ -4,10 +4,9 @@ import ( "errors" "fmt" - "github.com/bmatcuk/doublestar/v2" - "github.com/anchore/syft/syft/file" "github.com/anchore/syft/syft/sbom" + "github.com/bmatcuk/doublestar/v2" ) var errDoesNotProvide = fmt.Errorf("cannot provide packages from the given source") diff --git a/xeol/pkg/provider_test.go b/xeol/pkg/provider_test.go index 9b913a2..e6d8cd1 100644 --- a/xeol/pkg/provider_test.go +++ b/xeol/pkg/provider_test.go @@ -3,11 +3,10 @@ package pkg import ( "testing" - "github.com/stretchr/testify/assert" - "github.com/anchore/stereoscope/pkg/imagetest" "github.com/anchore/syft/syft" "github.com/anchore/syft/syft/file" + "github.com/stretchr/testify/assert" ) func TestProviderLocationExcludes(t *testing.T) { diff --git a/xeol/pkg/purl_provider.go b/xeol/pkg/purl_provider.go index 28d48fa..90f608d 100644 --- a/xeol/pkg/purl_provider.go +++ b/xeol/pkg/purl_provider.go @@ -7,11 +7,10 @@ import ( "os" "strings" - "github.com/mitchellh/go-homedir" - "github.com/anchore/packageurl-go" "github.com/anchore/syft/syft/cpe" "github.com/anchore/syft/syft/pkg" + "github.com/mitchellh/go-homedir" ) const ( diff --git a/xeol/pkg/syft_provider.go b/xeol/pkg/syft_provider.go index b0b5b9e..8b11209 100644 --- a/xeol/pkg/syft_provider.go +++ b/xeol/pkg/syft_provider.go @@ -11,6 +11,7 @@ import ( "github.com/anchore/syft/syft/sbom" "github.com/anchore/syft/syft/source" "github.com/anchore/syft/syft/source/sourceproviders" + "github.com/xeol-io/xeol/internal/log" ) diff --git a/xeol/pkg/syft_sbom_provider.go b/xeol/pkg/syft_sbom_provider.go index a222b18..3713493 100644 --- a/xeol/pkg/syft_sbom_provider.go +++ b/xeol/pkg/syft_sbom_provider.go @@ -7,11 +7,11 @@ import ( "os" "strings" + "github.com/anchore/syft/syft/format" + "github.com/anchore/syft/syft/sbom" "github.com/gabriel-vasile/mimetype" "github.com/mitchellh/go-homedir" - "github.com/anchore/syft/syft/format" - "github.com/anchore/syft/syft/sbom" "github.com/xeol-io/xeol/internal" "github.com/xeol-io/xeol/internal/log" ) diff --git a/xeol/pkg/syft_sbom_provider_test.go b/xeol/pkg/syft_sbom_provider_test.go index a0b0018..ee0b167 100644 --- a/xeol/pkg/syft_sbom_provider_test.go +++ b/xeol/pkg/syft_sbom_provider_test.go @@ -5,14 +5,13 @@ import ( "strings" "testing" - "github.com/go-test/deep" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" - "github.com/anchore/syft/syft/cpe" "github.com/anchore/syft/syft/file" "github.com/anchore/syft/syft/linux" "github.com/anchore/syft/syft/source" + "github.com/go-test/deep" + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" ) func TestParseSyftJSON(t *testing.T) { diff --git a/xeol/pkg/upstream_package.go b/xeol/pkg/upstream_package.go index 73326cd..dbccc18 100644 --- a/xeol/pkg/upstream_package.go +++ b/xeol/pkg/upstream_package.go @@ -3,9 +3,8 @@ package pkg import ( "strings" - "github.com/scylladb/go-set/strset" - "github.com/anchore/syft/syft/cpe" + "github.com/scylladb/go-set/strset" ) type UpstreamPackage struct { diff --git a/xeol/pkg/upstream_package_test.go b/xeol/pkg/upstream_package_test.go index 05a9665..4628078 100644 --- a/xeol/pkg/upstream_package_test.go +++ b/xeol/pkg/upstream_package_test.go @@ -3,9 +3,8 @@ package pkg import ( "testing" - "github.com/stretchr/testify/assert" - "github.com/anchore/syft/syft/cpe" + "github.com/stretchr/testify/assert" ) func TestUpstreamPackages(t *testing.T) {