You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Tried to move the package k8s.io/api, which rewrote all imports of k8s.io/apimachinery.
Reproducible example:
#!/bin/bash -e
GOPATH=$( mktemp -d )trap"{ CODE=$?; rm -rf $GOPATH ; exit $CODE; }" EXIT
# Make three packages. "example/foo", "example/fooooo" and "example/bar".# "example/bar" imports "example/fooooo"
mkdir -p $GOPATH/src/example/foo
mkdir -p $GOPATH/src/example/fooooo
mkdir -p $GOPATH/src/example/bar
echo"package foo">$GOPATH/src/example/foo/foo.go
echo"package foobar">$GOPATH/src/example/fooooo/fooooo.go
cat <<EOF > $GOPATH/src/example/bar/bar.gopackage barimport _ "example/fooooo"EOFecho"Before gomvpkg"
go list example/...
# Renaming "example/foo" impacts "example/bar" even though "example/bar" doesn't import it.
gomvpkg -from example/foo -to example/spam
echo"After gomvpkg"
go list example/...
cat $GOPATH/src/example/bar/bar.go
This script rewrites imports of example/fooooo even though it moves example/foo.
$ ./gomvpkg.sh Before gomvpkgexample/barexample/fooexample/foooooAfter gomvpkgexample/barexample/foooooexample/spampackage bar// Import should be "example/fooooo" but will be renamed "example/spamfoo"import _ "example/spamooo"
What did you expect to see?
Moving k8s.io/api, to not rewrite imports of k8s.io/apimachinery.
The text was updated successfully, but these errors were encountered:
Please answer these questions before submitting your issue. Thanks!
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
Yes
What operating system and processor architecture are you using (
go env
)?What did you do?
Tried to move the package
k8s.io/api
, which rewrote all imports ofk8s.io/apimachinery
.Reproducible example:
This script rewrites imports of
example/fooooo
even though it movesexample/foo
.What did you expect to see?
Moving
k8s.io/api
, to not rewrite imports ofk8s.io/apimachinery
.The text was updated successfully, but these errors were encountered: