Skip to content

Commit

Permalink
build(mage): 🐛 don't generate environment for go generate
Browse files Browse the repository at this point in the history
  • Loading branch information
joshuar committed Oct 3, 2024
1 parent 144fe32 commit da38244
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions build/magefiles/preps.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,14 +54,9 @@ func (Preps) Format() error {
// Generate ensures all machine-generated files (gotext, stringer, moq, etc.)
// are up to date.
func (Preps) Generate() error {
envMap, err := generateEnv()
if err != nil {
return errors.Join(ErrBuildFailed, err)
}

slog.Info("Running go generate...")

if err := sh.RunWithV(envMap, "go", "generate", "./..."); err != nil {
if err := sh.RunV("go", "generate", "./..."); err != nil {
return fmt.Errorf("failed to run go generate: %w", err)
}

Expand Down

0 comments on commit da38244

Please sign in to comment.