mirror of
https://github.com/kubernetes-sigs/kustomize.git
synced 2026-05-18 03:45:12 +00:00
Remove unnecessary import aliases.
This commit is contained in:
@@ -17,7 +17,7 @@ limitations under the License.
|
||||
package patch
|
||||
|
||||
import (
|
||||
yamlpatch "github.com/krishicks/yaml-patch"
|
||||
"github.com/krishicks/yaml-patch"
|
||||
)
|
||||
|
||||
// PatchJson6902 represents a json patch for an object
|
||||
|
||||
@@ -19,14 +19,13 @@ package transformer
|
||||
import (
|
||||
"fmt"
|
||||
|
||||
jsonpatch "github.com/evanphx/json-patch"
|
||||
yamlpatch "github.com/krishicks/yaml-patch"
|
||||
"k8s.io/apimachinery/pkg/runtime/schema"
|
||||
|
||||
"github.com/evanphx/json-patch"
|
||||
"github.com/krishicks/yaml-patch"
|
||||
"github.com/kubernetes-sigs/kustomize/pkg/loader"
|
||||
"github.com/kubernetes-sigs/kustomize/pkg/patch"
|
||||
"github.com/kubernetes-sigs/kustomize/pkg/resource"
|
||||
"github.com/kubernetes-sigs/kustomize/pkg/transformers"
|
||||
"k8s.io/apimachinery/pkg/runtime/schema"
|
||||
)
|
||||
|
||||
// PatchJson6902Factory makes PatchJson6902 transformers.
|
||||
|
||||
@@ -20,10 +20,9 @@ import (
|
||||
"strings"
|
||||
"testing"
|
||||
|
||||
yaml "gopkg.in/yaml.v2"
|
||||
|
||||
"github.com/kubernetes-sigs/kustomize/pkg/internal/loadertest"
|
||||
"github.com/kubernetes-sigs/kustomize/pkg/patch"
|
||||
"gopkg.in/yaml.v2"
|
||||
)
|
||||
|
||||
func TestNewPatchJson6902FactoryNull(t *testing.T) {
|
||||
|
||||
@@ -17,8 +17,7 @@ limitations under the License.
|
||||
package transformer
|
||||
|
||||
import (
|
||||
jsonpatch "github.com/evanphx/json-patch"
|
||||
|
||||
"github.com/evanphx/json-patch"
|
||||
"github.com/kubernetes-sigs/kustomize/pkg/resmap"
|
||||
"github.com/kubernetes-sigs/kustomize/pkg/resource"
|
||||
"github.com/kubernetes-sigs/kustomize/pkg/transformers"
|
||||
|
||||
@@ -20,8 +20,7 @@ import (
|
||||
"reflect"
|
||||
"testing"
|
||||
|
||||
jsonpatch "github.com/evanphx/json-patch"
|
||||
|
||||
"github.com/evanphx/json-patch"
|
||||
"github.com/kubernetes-sigs/kustomize/pkg/resmap"
|
||||
"github.com/kubernetes-sigs/kustomize/pkg/resource"
|
||||
)
|
||||
|
||||
@@ -18,8 +18,7 @@ package transformer
|
||||
|
||||
import (
|
||||
"github.com/ghodss/yaml"
|
||||
yamlpatch "github.com/krishicks/yaml-patch"
|
||||
|
||||
"github.com/krishicks/yaml-patch"
|
||||
"github.com/kubernetes-sigs/kustomize/pkg/resmap"
|
||||
"github.com/kubernetes-sigs/kustomize/pkg/resource"
|
||||
"github.com/kubernetes-sigs/kustomize/pkg/transformers"
|
||||
|
||||
@@ -20,7 +20,7 @@ import (
|
||||
"reflect"
|
||||
"testing"
|
||||
|
||||
yamlpatch "github.com/krishicks/yaml-patch"
|
||||
"github.com/krishicks/yaml-patch"
|
||||
"github.com/kubernetes-sigs/kustomize/pkg/resmap"
|
||||
"github.com/kubernetes-sigs/kustomize/pkg/resource"
|
||||
"k8s.io/apimachinery/pkg/runtime/schema"
|
||||
|
||||
@@ -27,7 +27,7 @@ import (
|
||||
func findTargetObj(m resmap.ResMap, targetId resource.ResId) (*resource.Resource, error) {
|
||||
matchedIds := m.FindByGVKN(targetId)
|
||||
if targetId.Namespace() != "" {
|
||||
ids := []resource.ResId{}
|
||||
var ids []resource.ResId
|
||||
for _, id := range matchedIds {
|
||||
if id.Namespace() == targetId.Namespace() {
|
||||
ids = append(ids, id)
|
||||
|
||||
Reference in New Issue
Block a user