Rework distributing jobs over repo workers.

- Fixed a number of bugs with splitting list of packages to a number of workers
- Now worker processes start their work only when a main process is ready to
process output.