Fork me on GitHub
#tools-deps
<
2023-05-22
>
Drew Verlee03:05:51

Is there a way to avoid declaring the mvn/root in a project, if the local/root dependency that uses it already has declared the mvn/root? For example, the example project below depends on local project f, which uses something found in the blah repo.

{:deps {f/f {:local/root "../f"}}
But if i try to build this, it fails, because it can't find blah. But if I add the mvn repo where blah is found, it works (as expected)
... :mnv/repo {"blah" {:URL "blahs url}}
But mvn/repo is already declared in the f project, so it feels like i'm declaring it twice for no added benefit.

seancorfield03:05:46

It's to avoid possible hijacking of dependencies by a transitive dep.

🙏 2
Alex Miller (Clojure team)03:05:22

The added benefit is that you know you declared it

🙏 2
Drew Verlee03:05:32

Gotcha. Thanks for the follow-up!