private function addRepository(
        RepositoryManager $repoManager, array &$repositories, $repoJson
    ) {
        if (isset($repoJson['type'])) {
            $this->getLogger()->info("Prepending {$repoJson['type']} repository");

            $repository = $repoManager->createRepository($repoJson['type'], $repoJson);

            $repoManager->prependRepository($repository);
            $repositories[] = $repository;
        }
    }