Should I checkin pkg/mod/cache to git?

216 Views Asked by At

I'm using go mod for my project. If my understanding is right, go.mod and go.sum can be checked in. However, I'm curious to know if I should check in pkg/mod/cache as well.

enter image description here

1

There are 1 best solutions below

0
Volker On BEST ANSWER

Should I checkin pkg/mod/cache to git?

No.

If you want to vendor your dependencies use go mod vendor.