How can I create a basis for an absolute path if the JVM's current directory is unrelated? e.g.
user> (tools.deps/create-basis {:project "/Users/vemv/foo/bar/deps.edn"})
Execution error (ExceptionInfo) at clojure.tools.deps.extensions.local/ensure-file (local.clj:41).
Local lib yyy not found: xxx
what's failing is that a dependency is defined like this: foo/bar {:local/root "../../baz"} so it's tripping up due to my unrelated CWD.
(names redacted)You can wrap in c.t.deps.util.dir/with-dir
It will use that as if it was the cwd
Thank you! 🙏
You might want to consider an addition to the create-basis docstring
You shouldn’t need to set the :project then either
> You shouldn’t need to set the :project then either I tried this and my tests began failing 🥲
Well I could be crazy but I would expect it to use deps.edn as the relative path, resolved against the with-dir
(Sorry if FAQ)
Given :deps {x/x {:local/root "../../x"}}, can I pull in its aliases too?
e.g. it defines :dev, I'd like to use its :dev alias from the dependent project
Some extra context: ../../x is not under my control (not without forking) so I can't simply re-architect things
Not currently
Thanks, I voted on https://ask.clojure.org/index.php/7843/allow-specifying-aliases-coordinates-that-point-projects