This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2018-11-12
Channels
- # announcements (2)
- # beginners (104)
- # cider (2)
- # cljs-dev (26)
- # cljsrn (1)
- # clojure (125)
- # clojure-dev (27)
- # clojure-italy (24)
- # clojure-nl (24)
- # clojure-russia (4)
- # clojure-spec (10)
- # clojure-uk (83)
- # clojurescript (18)
- # code-reviews (102)
- # community-development (14)
- # core-async (18)
- # cryogen (11)
- # cursive (15)
- # datomic (16)
- # emacs (6)
- # figwheel-main (6)
- # fulcro (142)
- # graphql (5)
- # jobs (5)
- # jobs-discuss (18)
- # kaocha (1)
- # keechma (1)
- # leiningen (20)
- # luminus (1)
- # mount (5)
- # pedestal (4)
- # reagent (17)
- # reitit (8)
- # shadow-cljs (29)
- # tools-deps (19)
- # vim (108)
Hello,
Is there a way to deploy an uberjar instead of a jar to clojars using lein deploy
?
Based on this, looks like it will only deploy a thin jar: https://github.com/technomancy/leiningen/blob/master/src/leiningen/deploy.clj#L152
don’t deploy uberjars to Maven repos
@rahul080327 I would ask why you would want to deploy an uberjar? Uberjars that include one version of clojure produce strange errors when consumed by a project that uses another version of clojure.
...actually, reading further it looks like you could probably deploy an uberjar by lein deploy clojars my.foo/bar 1.2.3 target/my-uber.jar
But yes, this is not what clojars is for
uberjars embed deps, making them hidden and hard to change
and if you deploy them, you are a Bad Person :)
I’ve found uberjar deploying to be useful from an internal company standpoint. If you want to deploy release artifacts that are released as uberjar apps
jk, but I have wasted many hours of my life debugging stuff like this from maven repos
so, internal deploys might be ok
I’m talking about clojars / maven central
if it’s internal, you can at least track who did it and steal their office chair
good practice
With that said. In terms of the root question (pending they didn’t wish to do it for malicious clojars/central deploy purposes) I can’t remember if you can coerce the plain lein deploy to do this. There are a few plugins out there to do similar, but we ended up with our own because we wanted a multi-classifier-artifact deploy task for various reasons.