diff --git a/pkg/update/update.go b/pkg/update/update.go index 671f373f5..3c348d37a 100644 --- a/pkg/update/update.go +++ b/pkg/update/update.go @@ -369,7 +369,7 @@ func (o *Options) updateGitPackage(ctx context.Context, repo *git.Repository, pa root := worktree.Filesystem.Root() log.Printf("working directory: %s", root) - configFile := filepath.Join(root, pc.Filename) + configFile := filepath.Join(pc.Dir, pc.Filename) if configFile == "" { return "", fmt.Errorf("no config filename found for package %s", packageName) } @@ -416,7 +416,7 @@ func (o *Options) updateGitPackage(ctx context.Context, repo *git.Repository, pa } // now make sure update config is configured - updated, err := config.ParseConfiguration(ctx, filepath.Join(root, pc.Filename)) + updated, err := config.ParseConfiguration(ctx, filepath.Join(pc.Dir, pc.Filename)) if err != nil { return "", fmt.Errorf("failed to parse %v", err) } @@ -435,7 +435,7 @@ func (o *Options) updateGitPackage(ctx context.Context, repo *git.Repository, pa // Skip any processing for definitions with a single pipeline if len(updated.Pipeline) > 1 { - if err := o.updateGoBumpDeps(updated, root, pc.Filename, mutations); err != nil { + if err := o.updateGoBumpDeps(updated, pc.Dir, pc.Filename, mutations); err != nil { return fmt.Sprintf("error cleaning up go/bump deps: %v", err), nil } }