Fork me on GitHub

can find-versions also work for non jar artifacts? I tried to find the versions for a published zip and I get no results. Checked the source code and it's not supported. Maven is an artifact repositoy and in essence you can store whatever artifacts there. Most of them are jars, but they don't need to be. Also: can it work for classifiers as well ? Don't use them right now, I'm asking for completion sake.

Alex Miller (Clojure team)12:09:52

It is jar only, although you are conceptually correct

Alex Miller (Clojure team)12:09:54

It might work for classifiers, which we do support, can’t actually say that I thought about it. Did you try it?


I did not try with classifier since I don't use it now - I can probably find a dependency online that has classifier and try with that

Alex Miller (Clojure team)12:09:13

The syntax is group/artifact$classifier


does tools-deps take into account encrypted server passwords from settings-security.xml ? Browsed the code and I did not see any references so I imagine it does not.

Alex Miller (Clojure team)12:09:08

We use the Maven apis to access those, so not sure if we are getting that support or not. Probably not would be my guess


Is there a way I can get the latest version of an artifact ? I tried this but it does not work ( I get the older version)

:deps { {:mvn/version "LATEST" :extension "zip"}}}}
This is perhaps related to find-versions . This is perhaps related to repository metadata refresh. The dependencies are available locally so it does not refresh them from upstream. Any way to force a metadata refresh via resolve-deps ?

Alex Miller (Clojure team)12:09:03

LATEST or RELEASE should resolve metadata

Alex Miller (Clojure team)12:09:28

I think it is subject to the once-per-day update policy though

Alex Miller (Clojure team)12:09:54

No ways to force that other than deleting repo metadata files from m2

Alex Miller (Clojure team)12:09:12

But that :extension is not a thing

Alex Miller (Clojure team)12:09:06

Tools.deps is not a generic interface to Maven, it’s a tool for building classpaths


If I remember correctly updatePolicy can be configured per maven repository in pom.xml


So maybe tools.deps could have a way to configure that in deps.esn


Somewhere in :mvn/repos

Alex Miller (Clojure team)12:09:34

Has been requested, and I even wrote the code at one point, but I’m going to resist that for now

Alex Miller (Clojure team)12:09:11

It adds a lot of complexity to other assumptions in the code


plus LATEST or RELEASE are refs not values, yuck


@ghadi: that is life 🙂


my life is based on values 🙂

👍 2
😄 2

if find-versions works with :extension I can avoid using LATEST/RELEASE


I can fetch latest version and use it

Alex Miller (Clojure team)12:09:01

If you want to get non-jars, you’re going to have to tap into a much lower point in the implementation

Alex Miller (Clojure team)12:09:17

This is not part of the public api