Recompile all packages after upgrade Go?

After updating Go, how can I make sure that all my packages in $GOPATH/pkg and the binaries in $GOPATH/bin recompiled using the new version?

I would like any update errors to be reported as warnings, not errors that cause the operation to be interrupted.

+5
source share
1 answer

Assuming you have one GOPATH path, you can upgrade all packages by doing the following:

cd $GOPATH/src go get -u -v ./...

If you have several GOPATHs, you need to enter the src folder of each of them and run:

go get -u -v ./...

Then run go install all

0
source

Source: https://habr.com/ru/post/1274191/


All Articles