Refactor dependency downloads.