New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cmd/go: no way to vendor symlink files with Go modules #39600
Comments
Not all filesystems in current use support symlinks. The module file formats are intended to be portable, so symlinks are intentionally skipped (see #27093 and #24057 (comment)). |
What did you do to try to populate it? |
Below is what we tried:
Right now we are using a very hacky way to get these symlinks:
|
You should be able to find the actual files underlying the links using Your |
Closing as not providing a large enough benefit to outweigh the churn of invalidating checksums. |
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
)?go env
OutputWhat did you do?
knative.dev/serving
project using Go modules, and needs these symlinks inconfig/
as well.What did you expect to see?
The symlinks can be vendored by the downstream project by either
dummy.go
file under theconfig/
package, and addingimport _ "knative.dev/serving/config
in one of the Go filesor
What did you see instead?
The symlinks cannot be vendored by using the first approach (adding a
dummy.go
file), and it cannot be vendored by force copying either, as when we rungo list -f '{{.Dir}}' -mod=readonly -m knative.dev/serving
, the local mod directory does not contain the symlinks in the first place.The text was updated successfully, but these errors were encountered: