robfig / glock

MIT License
230 stars 27 forks source link

Speed up glock sync #14

Closed robfig closed 7 years ago

robfig commented 9 years ago

It should be possible to make glock sync very fast in the case where everything is already up to date. That would reduce the cost of running it more frequently, for example as part of a build or deploy process.

Presently, it takes about 7 seconds for my config (from work) on a perfectly synced GOPATH.

robfig commented 9 years ago

Pushed https://github.com/robfig/glock/commit/5164a8113968e9b28a8e773568a3426098c8792d and https://github.com/robfig/glock/commit/6885d0e1a185d8c5f03747e374030a22dac99e63 which get the time down to 1.3 seconds for me.

Now the slowest part is installing the packages. I don't especially want to invoke the go tool in parallel, since I'm not sure if that's safe. The ideal thing would be to pass all of the packages to "go install" at once, but then I will have to be smart about figuring out which ones were built and which ones had build errors...