Set dependencies refactor

Doing both `go get` and checkout in the same loop made gpm prone to race conditions - happening when we tried to set versions for packages at the same time they were being installed.

Having this happening in two different loops makes the approach more tidy and less prone to error.