Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

internal/wire: update the path of wire which go generate run wire cmd #383

Open
edocevol opened this issue May 4, 2023 · 0 comments
Open

Comments

@edocevol
Copy link

edocevol commented May 4, 2023

Is your feature request related to a problem? Please describe.

Currently, wire generate wire_gen file with following codes,

// Code generated by Wire. DO NOT EDIT.

//go:generate go run github.com/google/wire/cmd/wire
//go:build !wireinject
// +build !wireinject

package xxx

But, as Golang release 1.16+ version, the exec command go:generate go run github.com/google/wire/cmd/wire is incompatible. Mayby got the following error:

../../go/pkg/mod/github.com/google/wire@v0.5.0/cmd/wire/main.go:34:2: missing go.sum entry for module providing package github.com/google/subcommands (imported by github.com/google/wire/cmd/wire); to add:
        go get github.com/google/wire/cmd/wire@v0.5.0
../../go/pkg/mod/github.com/google/wire@v0.5.0/internal/wire/copyast.go:21:2: missing go.sum entry for module providing package golang.org/x/tools/go/ast/astutil (imported by github.com/google/wire/internal/wire); to add:
        go get github.com/google/wire/internal/wire@v0.5.0
../../go/pkg/mod/github.com/google/wire@v0.5.0/internal/wire/parse.go:30:2: missing go.sum entry for module providing package golang.org/x/tools/go/packages (imported by github.com/google/wire/internal/wire); to add:
        go get github.com/google/wire/internal/wire@v0.5.0
../../go/pkg/mod/github.com/google/wire@v0.5.0/internal/wire/analyze.go:26:2: missing go.sum entry for module providing package golang.org/x/tools/go/types/typeutil (imported by github.com/google/wire/cmd/wire); to add:
        go get github.com/google/wire/cmd/wire@v0.5.0

Describe the solution you'd like

This feature added by #268, maybe we need something for update.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant