This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2020-12-28
Channels
- # announcements (5)
- # asami (34)
- # babashka (15)
- # beginners (222)
- # calva (5)
- # cider (2)
- # circleci (4)
- # cljfx (11)
- # clojure (34)
- # clojure-europe (10)
- # clojure-nl (2)
- # clojure-taiwan (2)
- # clojure-uk (5)
- # clojurescript (27)
- # conjure (8)
- # cryogen (11)
- # cursive (11)
- # datomic (7)
- # depstar (6)
- # fulcro (29)
- # graalvm (2)
- # joker (3)
- # kaocha (9)
- # nrepl (4)
- # off-topic (9)
- # pathom (1)
- # shadow-cljs (11)
- # spacemacs (4)
- # sql (1)
- # tools-deps (12)
@maxp Yes, if you're publishing a (library) JAR to Clojars or Maven Central, you need a pom.xml
file that is deployed alongside the JAR (technically, the process could just look in the JAR file for a suitable pom.xml
but I believe deployment would still need to know the group/artifact IDs -- which it can read easily from a pom.xml
file!). But the pom.xml
file can be entirely external to the JAR-building process since deployment only needs the JAR and the pom.xml
file -- so building a library JAR doesn't require a pom.xml
file but deploying it does.
If you're building a standalone (uber) JAR then you don't really need a pom.xml
file. depstar
can build uberjars without any additional information, that you can execute with java -cp path/to/the.jar clojure.main -m my.entry.point
Given a MANIFEST.MF
file, specifying Main-Class: clojure.main
you can just do java -jar path/to/the.jar -m my.entry.point
(because it executes clojure.main/-main
automatically).
I'm planning to refactor/cleanup the code quite a bit "soon" and then I'll rethink how a lot of the pom-related stuff needs to work. In theory, you could just provide the information depstar
needs via command-line arguments and it wouldn't need a pom.xml
for anything (but it's still "good practice" to have one or generate one).