mirror of
https://gitea.com/Lydanne/buildx.git
synced 2025-07-15 07:57:07 +08:00
vendor: golang.org/x/exp v0.0.0-20241108190413-2d47ceb2692f
full diff: 701f63a606...2d47ceb269
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
6
vendor/golang.org/x/tools/go/packages/external.go
generated
vendored
6
vendor/golang.org/x/tools/go/packages/external.go
generated
vendored
@ -79,7 +79,7 @@ type DriverResponse struct {
|
||||
|
||||
// driver is the type for functions that query the build system for the
|
||||
// packages named by the patterns.
|
||||
type driver func(cfg *Config, patterns ...string) (*DriverResponse, error)
|
||||
type driver func(cfg *Config, patterns []string) (*DriverResponse, error)
|
||||
|
||||
// findExternalDriver returns the file path of a tool that supplies
|
||||
// the build system package structure, or "" if not found.
|
||||
@ -103,7 +103,7 @@ func findExternalDriver(cfg *Config) driver {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
return func(cfg *Config, words ...string) (*DriverResponse, error) {
|
||||
return func(cfg *Config, patterns []string) (*DriverResponse, error) {
|
||||
req, err := json.Marshal(DriverRequest{
|
||||
Mode: cfg.Mode,
|
||||
Env: cfg.Env,
|
||||
@ -117,7 +117,7 @@ func findExternalDriver(cfg *Config) driver {
|
||||
|
||||
buf := new(bytes.Buffer)
|
||||
stderr := new(bytes.Buffer)
|
||||
cmd := exec.CommandContext(cfg.Context, tool, words...)
|
||||
cmd := exec.CommandContext(cfg.Context, tool, patterns...)
|
||||
cmd.Dir = cfg.Dir
|
||||
// The cwd gets resolved to the real path. On Darwin, where
|
||||
// /tmp is a symlink, this breaks anything that expects the
|
||||
|
Reference in New Issue
Block a user