mirror of
https://github.com/rancher/norman.git
synced 2025-09-17 15:49:53 +00:00
@@ -3,6 +3,7 @@ package generator
|
|||||||
var schemeTemplate = `package {{.version.Version}}
|
var schemeTemplate = `package {{.version.Version}}
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||||
"k8s.io/apimachinery/pkg/runtime"
|
"k8s.io/apimachinery/pkg/runtime"
|
||||||
"k8s.io/apimachinery/pkg/runtime/schema"
|
"k8s.io/apimachinery/pkg/runtime/schema"
|
||||||
)
|
)
|
||||||
@@ -37,6 +38,7 @@ func addKnownTypes(scheme *runtime.Scheme) error {
|
|||||||
{{range .names}}
|
{{range .names}}
|
||||||
&{{.}}{},{{end}}
|
&{{.}}{},{{end}}
|
||||||
)
|
)
|
||||||
|
metav1.AddToGroupVersion(scheme, SchemeGroupVersion)
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
`
|
`
|
||||||
|
Reference in New Issue
Block a user