This PR aims to fix bloating go.sum and vendor with dependencies from tools.go.
I have created a project with one simple interface and no imports. After generating mocks and running go mod tidy && go mod vendor I end up with way too many dependencies, most of which are not required for minimock to function. Moving tools to a separate module significantly reduces both number of dependencies and size of vendor
Latest master:
wc -l ./pr1/go.sum
1525 ./pr1/go.sum
du -sh ./pr1/vendor
55M ./pr1/vendor
After this PR:
wc -l ./pr2/go.sum
121 ./pr2/go.sum
du -sh ./pr2/vendor
240K ./pr2/vendor
Code used to reproduce:
package main
type Adder interface {
Add(a, b int) int
}
This PR aims to fix bloating
go.sum
andvendor
with dependencies fromtools.go
.I have created a project with one simple interface and no imports. After generating mocks and running
go mod tidy && go mod vendor
I end up with way too many dependencies, most of which are not required forminimock
to function. Moving tools to a separate module significantly reduces both number of dependencies and size ofvendor
Latest master:
After this PR:
Code used to reproduce: