kubectl-neat icon indicating copy to clipboard operation
kubectl-neat copied to clipboard

Remove `replace` directives in go.mod so `go install` works

Open howardjohn opened this issue 4 years ago • 2 comments

$ go install github.com/itaysk/kubectl-neat@latest
go install github.com/itaysk/kubectl-neat@latest: github.com/itaysk/[email protected]
        The go.mod file for the module providing named packages contains one or
        more replace directives. It must not contain directives that would cause
        it to be interpreted differently than if it were the main module.

This can be fixed by removing the replaces in go.mod. I believe these are not needed anymore, or at least they will not be if the k8s client libraries are updated?

howardjohn avatar Apr 25 '21 23:04 howardjohn

Ah I realized now there is an import on kubernetes/kubernetes which may not be drop-able since we need the defaulting logic

howardjohn avatar Apr 25 '21 23:04 howardjohn

Ah I realized now there is an import on kubernetes/kubernetes which may not be drop-able since we need the defaulting logic

when I wrote kubectl-neat this was necessary, since of the way kubernetes' components were versioned and released. I don't know if there's a better solution today. I suspect there isn't but I would be happy to learn otherwise.

itaysk avatar Apr 26 '21 10:04 itaysk