Discovers branches on the repository.