From e49b475b9f7edf1077a4a619d56d811b142b6631 Mon Sep 17 00:00:00 2001 From: Kevin Hogeland Date: Mon, 1 Feb 2021 15:30:19 -0800 Subject: [PATCH] Ivy repo support --- coursier.bzl | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/coursier.bzl b/coursier.bzl index 2019b56b4..24e076191 100644 --- a/coursier.bzl +++ b/coursier.bzl @@ -829,11 +829,12 @@ def _coursier_fetch_impl(repository_ctx): # # TODO(https://github.com/bazelbuild/rules_jvm_external/issues/186): Make this work with # basic auth. - repository_urls = [r["repo_url"].rstrip("/") for r in repositories] + repository_urls = [r["repo_url"].rstrip("/") for r in repositories if not r["repo_url"].startswith("ivy:")] primary_artifact_path = infer_artifact_path_from_primary_and_repos(primary_url, repository_urls) - mirror_urls = [url + "/" + primary_artifact_path for url in repository_urls] - artifact.update({"mirror_urls": mirror_urls}) + if primary_artifact_path: + mirror_urls = [url + "/" + primary_artifact_path for url in repository_urls] + artifact.update({"mirror_urls": mirror_urls}) files_to_hash.append(repository_ctx.path(artifact["file"]))