Skip to content
This repository has been archived by the owner on Feb 24, 2024. It is now read-only.

Run go mod tidy when initializing a new project #2124

Merged
merged 2 commits into from
Jul 7, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@ jobs:
runs-on: ubuntu-latest
steps:
-
name: Set up Go 1.14
name: Set up Go 1.15
uses: actions/setup-go@v1
with:
go-version: 1.14
go-version: 1.15
id: go
-
name: Checkout Code
Expand Down
6 changes: 6 additions & 0 deletions buffalo/cmd/new.go
Original file line number Diff line number Diff line change
Expand Up @@ -201,6 +201,12 @@ var newCmd = &cobra.Command{
}
run.WithGroup(gg)

g := genny.New()
g.Command(exec.Command("go", "mod", "tidy"))
if err := run.With(g); err != nil {
return nil
}

if err := run.WithNew(gogen.Fmt(app.Root)); err != nil {
return err
}
Expand Down