Fork me on GitHub
#tools-deps
<
2023-12-14
>
octahedrion11:12:39

is there a way to specify an :extra-deps alias to a local library and use a :sha ? The reason is that I want to test different branches of the same local project each in its own REPL, so I'd have a different alias for each REPL each having an :extra-deps for the same library but a different sha for each. Or is there another way to do this ?

octahedrion11:12:42

... I tried using :local/root with a :sha but I get "Coord type is ambiguous:"

Alex Miller (Clojure team)13:12:30

You can use a git dep to the local dir

Alex Miller (Clojure team)13:12:30

I don’t off hand remember the git file url syntax but that should work and then you can use :git/sha with it

Alex Miller (Clojure team)13:12:04

I think it’s just basically a :git/url “<file:///srv/git/project.git|file:///srv/git/project.git>”

Alex Miller (Clojure team)13:12:18

Or you might be fine with just a path, not the url, try both

octahedrion08:12:35

Clojure's dependency system continues to surprise and delight. It worked beautifully and the file:// prefix for :git/url is optional as is the git namespace for :sha (edit: I see that's for backwards compatibility) . I am now able to test two branches of the same lib from another in separate REPLs and compare results. Thank you so much @U064X3EF3 !

Alex Miller (Clojure team)12:12:07

Yeah, :git/sha is the preferred key, :sha is deprecated