When enabling aliases when starting clojure, would it make sense to propagate those aliases when processing the deps.edn
files of (transitive) dependencies?
This is related to but different from: Allow specifying aliases in coordinates that point to deps.edn projects (JIRA TDEPS-116).
Use case:
I'm developing a number of interrelated libraries. One of them, lambdaisland/chui-ui
, has a dev dependency on garden. The released version does not need garden, it contains the compiled css instead.
chui-ui
is a dependency of chui
, and chui
is a dependency of kaocha-cljs2
. While working on either of these I use :local/root
to set up the dependencies, so that I can easily work across these different sources.
;; chui-ui
{:aliases
{:dev {:extra-deps {garden ...}}}}
;; chui
{:deps {chui-ui {:local/root "modules/chui-ui"}}}
;; kaocha-cljs2
{:deps {chui {:local/root "../chui"}}}
But this doesn't work as such, because when I start clojure -A:dev
inside chui
or kaocha-cljs2
, then the garden dependency is not picked up. To make this work I need to copy that :dev
alias with garden to the top level project, even though chui or kaocha-cljs2 are not concerned with garden.