Skip to content
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

Remember to include CLI Go source files in `go mod vendor` cache #35502

Closed
mcandre opened this issue Nov 11, 2019 · 2 comments

Comments

@mcandre
Copy link

@mcandre mcandre commented Nov 11, 2019

Please don't strip cmd paths from go mod vendor caches. Altering the source cache makes it that much harder to track tool dependencies and debug Go systems generally.

@bcmills

This comment has been minimized.

Copy link
Member

@bcmills bcmills commented Nov 11, 2019

Per https://golang.org/cmd/go/#hdr-Make_vendored_copy_of_dependencies:

Vendor resets the main module's vendor directory to include all packages needed to build and test all the main module's packages.

CLI main packages are not importable, and thus are not “needed to build and test all the main module's packages” (in the sense of go build or go test). Therefore, they are omitted by design.

@bcmills

This comment has been minimized.

Copy link
Member

@bcmills bcmills commented Nov 11, 2019

Duplicate of #29516

@bcmills bcmills marked this as a duplicate of #29516 Nov 11, 2019
@bcmills bcmills closed this Nov 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.