diff --git a/generator/overrides/gen.go b/generator/overrides/gen.go index dfece0e78..22b16fa85 100644 --- a/generator/overrides/gen.go +++ b/generator/overrides/gen.go @@ -127,7 +127,7 @@ func (g Generator) Generate(ctx *genall.GenerationContext) error { genutils.WriteFormattedSourceFile(fileNamePart, ctx, root, func(buf *bytes.Buffer) { buf.WriteString(` import ( - attributes "github.com/devfile/api/pkg/attributes" + attributes "github.com/devfile/api/v2/pkg/attributes" ) `) diff --git a/go.mod b/go.mod index 052fa6e41..9bfbdf494 100644 --- a/go.mod +++ b/go.mod @@ -1,4 +1,4 @@ -module github.com/devfile/api +module github.com/devfile/api/v2 go 1.13 diff --git a/pkg/apis/addtoscheme_workspaces_v1alpha2.go b/pkg/apis/addtoscheme_workspaces_v1alpha2.go index 5225d8394..6fb15f929 100644 --- a/pkg/apis/addtoscheme_workspaces_v1alpha2.go +++ b/pkg/apis/addtoscheme_workspaces_v1alpha2.go @@ -1,7 +1,7 @@ package apis import ( - "github.com/devfile/api/pkg/apis/workspaces/v1alpha2" + "github.com/devfile/api/v2/pkg/apis/workspaces/v1alpha2" ) func init() { diff --git a/pkg/apis/workspaces/v1alpha1/attributes_conversion.go b/pkg/apis/workspaces/v1alpha1/attributes_conversion.go index 664dd8a33..4221dc96a 100644 --- a/pkg/apis/workspaces/v1alpha1/attributes_conversion.go +++ b/pkg/apis/workspaces/v1alpha1/attributes_conversion.go @@ -2,7 +2,8 @@ package v1alpha1 import ( "fmt" - "github.com/devfile/api/pkg/attributes" + + "github.com/devfile/api/v2/pkg/attributes" ) func convertAttributesTo_v1alpha2(src map[string]string, dest *attributes.Attributes) { diff --git a/pkg/apis/workspaces/v1alpha1/commands_conversion.go b/pkg/apis/workspaces/v1alpha1/commands_conversion.go index 4f848aff2..b60369d85 100644 --- a/pkg/apis/workspaces/v1alpha1/commands_conversion.go +++ b/pkg/apis/workspaces/v1alpha1/commands_conversion.go @@ -2,9 +2,10 @@ package v1alpha1 import ( "encoding/json" - "github.com/devfile/api/pkg/attributes" - "github.com/devfile/api/pkg/apis/workspaces/v1alpha2" + "github.com/devfile/api/v2/pkg/attributes" + + "github.com/devfile/api/v2/pkg/apis/workspaces/v1alpha2" ) func convertCommandTo_v1alpha2(src *Command, dest *v1alpha2.Command) error { diff --git a/pkg/apis/workspaces/v1alpha1/commands_conversion_test.go b/pkg/apis/workspaces/v1alpha1/commands_conversion_test.go index 121388ddd..24cb00957 100644 --- a/pkg/apis/workspaces/v1alpha1/commands_conversion_test.go +++ b/pkg/apis/workspaces/v1alpha1/commands_conversion_test.go @@ -3,7 +3,7 @@ package v1alpha1 import ( "testing" - "github.com/devfile/api/pkg/apis/workspaces/v1alpha2" + "github.com/devfile/api/v2/pkg/apis/workspaces/v1alpha2" "github.com/google/go-cmp/cmp" fuzz "github.com/google/gofuzz" "github.com/stretchr/testify/assert" diff --git a/pkg/apis/workspaces/v1alpha1/components_conversion.go b/pkg/apis/workspaces/v1alpha1/components_conversion.go index 1ca059469..566f7193e 100644 --- a/pkg/apis/workspaces/v1alpha1/components_conversion.go +++ b/pkg/apis/workspaces/v1alpha1/components_conversion.go @@ -3,7 +3,7 @@ package v1alpha1 import ( "encoding/json" - "github.com/devfile/api/pkg/apis/workspaces/v1alpha2" + "github.com/devfile/api/v2/pkg/apis/workspaces/v1alpha2" ) func convertComponentTo_v1alpha2(src *Component, dest *v1alpha2.Component) error { diff --git a/pkg/apis/workspaces/v1alpha1/components_conversion_test.go b/pkg/apis/workspaces/v1alpha1/components_conversion_test.go index c3672dcf5..e658b7ab6 100644 --- a/pkg/apis/workspaces/v1alpha1/components_conversion_test.go +++ b/pkg/apis/workspaces/v1alpha1/components_conversion_test.go @@ -3,7 +3,7 @@ package v1alpha1 import ( "testing" - "github.com/devfile/api/pkg/apis/workspaces/v1alpha2" + "github.com/devfile/api/v2/pkg/apis/workspaces/v1alpha2" "github.com/google/go-cmp/cmp" fuzz "github.com/google/gofuzz" "github.com/stretchr/testify/assert" diff --git a/pkg/apis/workspaces/v1alpha1/conversion.go b/pkg/apis/workspaces/v1alpha1/conversion.go index 0d8068711..cb382d509 100644 --- a/pkg/apis/workspaces/v1alpha1/conversion.go +++ b/pkg/apis/workspaces/v1alpha1/conversion.go @@ -1,7 +1,7 @@ package v1alpha1 import ( - "github.com/devfile/api/pkg/apis/workspaces/v1alpha2" + "github.com/devfile/api/v2/pkg/apis/workspaces/v1alpha2" ) func convertDevWorkspaceTo_v1alpha2(src *DevWorkspace, dest *v1alpha2.DevWorkspace) error { diff --git a/pkg/apis/workspaces/v1alpha1/conversion_test.go b/pkg/apis/workspaces/v1alpha1/conversion_test.go index 23df06e44..4a3181cb1 100644 --- a/pkg/apis/workspaces/v1alpha1/conversion_test.go +++ b/pkg/apis/workspaces/v1alpha1/conversion_test.go @@ -3,7 +3,7 @@ package v1alpha1 import ( "testing" - "github.com/devfile/api/pkg/apis/workspaces/v1alpha2" + "github.com/devfile/api/v2/pkg/apis/workspaces/v1alpha2" "github.com/google/go-cmp/cmp" fuzz "github.com/google/gofuzz" "github.com/stretchr/testify/assert" diff --git a/pkg/apis/workspaces/v1alpha1/devworkspace_conversion.go b/pkg/apis/workspaces/v1alpha1/devworkspace_conversion.go index 8c831c88c..a4e01a4b8 100644 --- a/pkg/apis/workspaces/v1alpha1/devworkspace_conversion.go +++ b/pkg/apis/workspaces/v1alpha1/devworkspace_conversion.go @@ -1,7 +1,7 @@ package v1alpha1 import ( - "github.com/devfile/api/pkg/apis/workspaces/v1alpha2" + "github.com/devfile/api/v2/pkg/apis/workspaces/v1alpha2" "sigs.k8s.io/controller-runtime/pkg/conversion" ) diff --git a/pkg/apis/workspaces/v1alpha1/devworkspacetemplate_conversion.go b/pkg/apis/workspaces/v1alpha1/devworkspacetemplate_conversion.go index 8b87c5358..f74b766d8 100644 --- a/pkg/apis/workspaces/v1alpha1/devworkspacetemplate_conversion.go +++ b/pkg/apis/workspaces/v1alpha1/devworkspacetemplate_conversion.go @@ -1,7 +1,7 @@ package v1alpha1 import ( - "github.com/devfile/api/pkg/apis/workspaces/v1alpha2" + "github.com/devfile/api/v2/pkg/apis/workspaces/v1alpha2" "sigs.k8s.io/controller-runtime/pkg/conversion" ) diff --git a/pkg/apis/workspaces/v1alpha1/events_conversion.go b/pkg/apis/workspaces/v1alpha1/events_conversion.go index c25945772..4bef6227f 100644 --- a/pkg/apis/workspaces/v1alpha1/events_conversion.go +++ b/pkg/apis/workspaces/v1alpha1/events_conversion.go @@ -1,7 +1,7 @@ package v1alpha1 import ( - "github.com/devfile/api/pkg/apis/workspaces/v1alpha2" + "github.com/devfile/api/v2/pkg/apis/workspaces/v1alpha2" ) func convertEventsTo_v1alpha2(src *Events, dest *v1alpha2.Events) error { diff --git a/pkg/apis/workspaces/v1alpha1/events_conversion_test.go b/pkg/apis/workspaces/v1alpha1/events_conversion_test.go index f9c86cb63..dd10b5ac3 100644 --- a/pkg/apis/workspaces/v1alpha1/events_conversion_test.go +++ b/pkg/apis/workspaces/v1alpha1/events_conversion_test.go @@ -3,7 +3,7 @@ package v1alpha1 import ( "testing" - "github.com/devfile/api/pkg/apis/workspaces/v1alpha2" + "github.com/devfile/api/v2/pkg/apis/workspaces/v1alpha2" fuzz "github.com/google/gofuzz" "github.com/stretchr/testify/assert" ) diff --git a/pkg/apis/workspaces/v1alpha1/parent_conversion.go b/pkg/apis/workspaces/v1alpha1/parent_conversion.go index b8ab44029..bcdde1b71 100644 --- a/pkg/apis/workspaces/v1alpha1/parent_conversion.go +++ b/pkg/apis/workspaces/v1alpha1/parent_conversion.go @@ -3,7 +3,7 @@ package v1alpha1 import ( "encoding/json" - "github.com/devfile/api/pkg/apis/workspaces/v1alpha2" + "github.com/devfile/api/v2/pkg/apis/workspaces/v1alpha2" ) func convertParentTo_v1alpha2(src *Parent, dest *v1alpha2.Parent) error { diff --git a/pkg/apis/workspaces/v1alpha1/parent_conversion_test.go b/pkg/apis/workspaces/v1alpha1/parent_conversion_test.go index 83f211067..aaf7c8f69 100644 --- a/pkg/apis/workspaces/v1alpha1/parent_conversion_test.go +++ b/pkg/apis/workspaces/v1alpha1/parent_conversion_test.go @@ -3,7 +3,7 @@ package v1alpha1 import ( "testing" - "github.com/devfile/api/pkg/apis/workspaces/v1alpha2" + "github.com/devfile/api/v2/pkg/apis/workspaces/v1alpha2" "github.com/google/go-cmp/cmp" fuzz "github.com/google/gofuzz" "github.com/stretchr/testify/assert" diff --git a/pkg/apis/workspaces/v1alpha1/plugin_conversion.go b/pkg/apis/workspaces/v1alpha1/plugin_conversion.go index a75da82f7..56fc1c769 100644 --- a/pkg/apis/workspaces/v1alpha1/plugin_conversion.go +++ b/pkg/apis/workspaces/v1alpha1/plugin_conversion.go @@ -3,7 +3,7 @@ package v1alpha1 import ( "encoding/json" - "github.com/devfile/api/pkg/apis/workspaces/v1alpha2" + "github.com/devfile/api/v2/pkg/apis/workspaces/v1alpha2" ) func convertPluginComponentTo_v1alpha2(srcComponent *Component, destComponent *v1alpha2.Component) error { diff --git a/pkg/apis/workspaces/v1alpha1/projects_conversion.go b/pkg/apis/workspaces/v1alpha1/projects_conversion.go index 7fcca4995..bec94dffd 100644 --- a/pkg/apis/workspaces/v1alpha1/projects_conversion.go +++ b/pkg/apis/workspaces/v1alpha1/projects_conversion.go @@ -3,7 +3,7 @@ package v1alpha1 import ( "encoding/json" - "github.com/devfile/api/pkg/apis/workspaces/v1alpha2" + "github.com/devfile/api/v2/pkg/apis/workspaces/v1alpha2" ) func convertProjectTo_v1alpha2(src *Project, dest *v1alpha2.Project) error { diff --git a/pkg/apis/workspaces/v1alpha1/projects_conversion_test.go b/pkg/apis/workspaces/v1alpha1/projects_conversion_test.go index fecebda62..45d290161 100644 --- a/pkg/apis/workspaces/v1alpha1/projects_conversion_test.go +++ b/pkg/apis/workspaces/v1alpha1/projects_conversion_test.go @@ -3,7 +3,7 @@ package v1alpha1 import ( "testing" - "github.com/devfile/api/pkg/apis/workspaces/v1alpha2" + "github.com/devfile/api/v2/pkg/apis/workspaces/v1alpha2" fuzz "github.com/google/gofuzz" "github.com/stretchr/testify/assert" ) diff --git a/pkg/apis/workspaces/v1alpha2/commands.go b/pkg/apis/workspaces/v1alpha2/commands.go index 8ffd1f643..84d70e40e 100644 --- a/pkg/apis/workspaces/v1alpha2/commands.go +++ b/pkg/apis/workspaces/v1alpha2/commands.go @@ -1,7 +1,7 @@ package v1alpha2 import ( - attributes "github.com/devfile/api/pkg/attributes" + attributes "github.com/devfile/api/v2/pkg/attributes" runtime "k8s.io/apimachinery/pkg/runtime" ) diff --git a/pkg/apis/workspaces/v1alpha2/components.go b/pkg/apis/workspaces/v1alpha2/components.go index 72196a04c..20b4b682b 100644 --- a/pkg/apis/workspaces/v1alpha2/components.go +++ b/pkg/apis/workspaces/v1alpha2/components.go @@ -1,7 +1,7 @@ package v1alpha2 import ( - attributes "github.com/devfile/api/pkg/attributes" + attributes "github.com/devfile/api/v2/pkg/attributes" runtime "k8s.io/apimachinery/pkg/runtime" ) diff --git a/pkg/apis/workspaces/v1alpha2/devfile.go b/pkg/apis/workspaces/v1alpha2/devfile.go index cec214d90..2d4681521 100644 --- a/pkg/apis/workspaces/v1alpha2/devfile.go +++ b/pkg/apis/workspaces/v1alpha2/devfile.go @@ -1,7 +1,7 @@ package v1alpha2 import ( - "github.com/devfile/api/pkg/devfile" + "github.com/devfile/api/v2/pkg/devfile" ) // Devfile describes the structure of a cloud-native workspace and development environment. diff --git a/pkg/apis/workspaces/v1alpha2/endpoint.go b/pkg/apis/workspaces/v1alpha2/endpoint.go index 6f7cf48c5..f5484ce1e 100644 --- a/pkg/apis/workspaces/v1alpha2/endpoint.go +++ b/pkg/apis/workspaces/v1alpha2/endpoint.go @@ -1,7 +1,7 @@ package v1alpha2 import ( - attributes "github.com/devfile/api/pkg/attributes" + attributes "github.com/devfile/api/v2/pkg/attributes" ) // EndpointProtocol defines the application and transport protocols of the traffic that will go through this endpoint. diff --git a/pkg/apis/workspaces/v1alpha2/projects.go b/pkg/apis/workspaces/v1alpha2/projects.go index a812ce498..a111ac650 100644 --- a/pkg/apis/workspaces/v1alpha2/projects.go +++ b/pkg/apis/workspaces/v1alpha2/projects.go @@ -1,7 +1,7 @@ package v1alpha2 import ( - attributes "github.com/devfile/api/pkg/attributes" + attributes "github.com/devfile/api/v2/pkg/attributes" runtime "k8s.io/apimachinery/pkg/runtime" ) diff --git a/pkg/apis/workspaces/v1alpha2/zz_generated.deepcopy.go b/pkg/apis/workspaces/v1alpha2/zz_generated.deepcopy.go index 51d20b7bc..3ee9a3c32 100644 --- a/pkg/apis/workspaces/v1alpha2/zz_generated.deepcopy.go +++ b/pkg/apis/workspaces/v1alpha2/zz_generated.deepcopy.go @@ -5,7 +5,7 @@ package v1alpha2 import ( - "github.com/devfile/api/pkg/attributes" + "github.com/devfile/api/v2/pkg/attributes" "k8s.io/api/core/v1" "k8s.io/apimachinery/pkg/runtime" ) diff --git a/pkg/apis/workspaces/v1alpha2/zz_generated.parent_overrides.go b/pkg/apis/workspaces/v1alpha2/zz_generated.parent_overrides.go index c61417fa6..6de9855bd 100644 --- a/pkg/apis/workspaces/v1alpha2/zz_generated.parent_overrides.go +++ b/pkg/apis/workspaces/v1alpha2/zz_generated.parent_overrides.go @@ -1,7 +1,7 @@ package v1alpha2 import ( - attributes "github.com/devfile/api/pkg/attributes" + attributes "github.com/devfile/api/v2/pkg/attributes" ) // +devfile:jsonschema:generate diff --git a/pkg/apis/workspaces/v1alpha2/zz_generated.plugin_overrides.go b/pkg/apis/workspaces/v1alpha2/zz_generated.plugin_overrides.go index 362c2e660..b3c145394 100644 --- a/pkg/apis/workspaces/v1alpha2/zz_generated.plugin_overrides.go +++ b/pkg/apis/workspaces/v1alpha2/zz_generated.plugin_overrides.go @@ -1,7 +1,7 @@ package v1alpha2 import ( - attributes "github.com/devfile/api/pkg/attributes" + attributes "github.com/devfile/api/v2/pkg/attributes" ) // +devfile:jsonschema:generate diff --git a/pkg/devfile/header.go b/pkg/devfile/header.go index 108062a8c..23cccd04b 100644 --- a/pkg/devfile/header.go +++ b/pkg/devfile/header.go @@ -1,7 +1,7 @@ package devfile import ( - attributes "github.com/devfile/api/pkg/attributes" + attributes "github.com/devfile/api/v2/pkg/attributes" ) // DevfileHeader describes the structure of the devfile-specific top-level fields diff --git a/pkg/devfile/header_test.go b/pkg/devfile/header_test.go index 0c773bebb..b2efc796c 100644 --- a/pkg/devfile/header_test.go +++ b/pkg/devfile/header_test.go @@ -3,7 +3,7 @@ package devfile import ( "testing" - attributes "github.com/devfile/api/pkg/attributes" + attributes "github.com/devfile/api/v2/pkg/attributes" "github.com/stretchr/testify/assert" "sigs.k8s.io/yaml" ) diff --git a/pkg/utils/overriding/keys.go b/pkg/utils/overriding/keys.go index b88cbe8ba..cca05ca96 100644 --- a/pkg/utils/overriding/keys.go +++ b/pkg/utils/overriding/keys.go @@ -1,7 +1,7 @@ package overriding import ( - workspaces "github.com/devfile/api/pkg/apis/workspaces/v1alpha2" + workspaces "github.com/devfile/api/v2/pkg/apis/workspaces/v1alpha2" "github.com/hashicorp/go-multierror" "k8s.io/apimachinery/pkg/util/sets" ) diff --git a/pkg/utils/overriding/merging.go b/pkg/utils/overriding/merging.go index cb4aa63f0..95fbeb80f 100644 --- a/pkg/utils/overriding/merging.go +++ b/pkg/utils/overriding/merging.go @@ -5,7 +5,7 @@ import ( "reflect" "strings" - workspaces "github.com/devfile/api/pkg/apis/workspaces/v1alpha2" + workspaces "github.com/devfile/api/v2/pkg/apis/workspaces/v1alpha2" "k8s.io/apimachinery/pkg/util/json" "k8s.io/apimachinery/pkg/util/sets" "k8s.io/apimachinery/pkg/util/yaml" diff --git a/pkg/utils/overriding/overriding.go b/pkg/utils/overriding/overriding.go index 6edcc3d13..6eba4c417 100644 --- a/pkg/utils/overriding/overriding.go +++ b/pkg/utils/overriding/overriding.go @@ -5,8 +5,8 @@ import ( "reflect" "strings" - workspaces "github.com/devfile/api/pkg/apis/workspaces/v1alpha2" - unions "github.com/devfile/api/pkg/utils/unions" + workspaces "github.com/devfile/api/v2/pkg/apis/workspaces/v1alpha2" + unions "github.com/devfile/api/v2/pkg/utils/unions" "k8s.io/apimachinery/pkg/util/json" "k8s.io/apimachinery/pkg/util/sets" strategicpatch "k8s.io/apimachinery/pkg/util/strategicpatch" diff --git a/pkg/utils/overriding/overriding_test.go b/pkg/utils/overriding/overriding_test.go index 37faa4584..df82e794c 100644 --- a/pkg/utils/overriding/overriding_test.go +++ b/pkg/utils/overriding/overriding_test.go @@ -7,7 +7,7 @@ import ( "strings" "testing" - workspaces "github.com/devfile/api/pkg/apis/workspaces/v1alpha2" + workspaces "github.com/devfile/api/v2/pkg/apis/workspaces/v1alpha2" "github.com/stretchr/testify/assert" "k8s.io/apimachinery/pkg/util/json" yamlMachinery "k8s.io/apimachinery/pkg/util/yaml" diff --git a/pkg/utils/unions/normalize.go b/pkg/utils/unions/normalize.go index b611049d7..25ee67250 100644 --- a/pkg/utils/unions/normalize.go +++ b/pkg/utils/unions/normalize.go @@ -3,7 +3,7 @@ package unions import ( "reflect" - workspaces "github.com/devfile/api/pkg/apis/workspaces/v1alpha2" + workspaces "github.com/devfile/api/v2/pkg/apis/workspaces/v1alpha2" "github.com/mitchellh/reflectwalk" ) diff --git a/pkg/utils/unions/normalize_test.go b/pkg/utils/unions/normalize_test.go index 353a5c8bd..1e1fc14cd 100644 --- a/pkg/utils/unions/normalize_test.go +++ b/pkg/utils/unions/normalize_test.go @@ -3,7 +3,7 @@ package unions import ( "testing" - workspaces "github.com/devfile/api/pkg/apis/workspaces/v1alpha2" + workspaces "github.com/devfile/api/v2/pkg/apis/workspaces/v1alpha2" "github.com/stretchr/testify/assert" )