leiningen

N.B. The maintainers are on #leiningen on Libera chat IRC. Go there for direct support/bug reports.
chadhs 2020-04-08T10:47:20.027700Z

are most of you adding your lein plugins to your project dev profile rather than just to a top level :plugins

paul a 2020-04-08T13:13:46.029900Z

within my lein project, how would i use a non-lein project as a lein checkout? the docs (https://github.com/technomancy/leiningen/blob/stable/doc/TUTORIAL.md#checkout-dependencies) indicate that i would need to lein install the checkout in order to add the necessary files to my local maven repo, but since the checkout in question isn't a lein project, what am i to do?

paul a 2020-04-08T13:31:18.032300Z

i'm trying to test changes to a dependency (which is not a lein project) in the context of a lein project; i'd like to avoid figuring out of the finer points of putting jars and pom.xml into my local maven repo

paul a 2020-04-08T13:50:16.033900Z

well, i was able to glean that https://github.com/slipset/deps-deploy does something like what lein install does, although i haven't figured out a clj/deps alias that would be equivalent to lein install. i'm in place now where i'm seeing this when i try to run my code: Could not locate cljfx/api__init.class, cljfx/api.clj or cljfx/api.cljc on classpath.

paul a 2020-04-08T13:50:33.034500Z

(cljfx is the non-lein project that i'm trying to use as a checkout

2020-04-08T15:26:58.035400Z

@pclalv_clojurians lein install knows how to install things if there's a pom.xml and a jar, with some extra args it can use just a jar

2020-04-08T15:27:23.035800Z

clj -Spom will make a pom for deps.edn

alexmiller 2020-04-08T15:30:33.036300Z

if clj -Spom, you can probably tweak it, and then run mvn install

paul a 2020-04-08T18:54:36.037600Z

ah, okay. @noisesmith perhaps you meant lein deploy?

2020-04-08T18:57:22.037800Z

no, I meant lein install, it can do arbitrary artifacts

paul a 2020-04-08T19:06:21.040Z

oh huh. i don't see that and i'm on lein 2.9.2. lein install doesn't seem to accept any args or options (looking at the CLI help output), whereas lein deploy does. i was just now able to use lein deploy to put some jars into ~/.m2/repository; i'm still getting the same classpath error, but maybe i need to keep plugging away at it

alexmiller 2020-04-08T19:06:46.040400Z

You can do that with mvn install

alexmiller 2020-04-08T19:07:11.041200Z

It takes a bunch of args (jar file, pom file, etc)

paul a 2020-04-08T19:07:19.041400Z

oh right, mvn install. somehow i didn't notice those three letters in your earlier message

paul a 2020-04-08T19:52:51.044800Z

i can run mvn install without error, and it definitely adds things to my local maven repo, but something's still not right - i'm still getting the classpath-related error, Could not locate cljfx/jdk/platform__init.class, cljfx/jdk/platform.clj or cljfx/jdk/platform.cljc on classpath. the error is all but inscrutable - i'm way out of my element with these low-level java errors 😖

alexmiller 2020-04-08T20:12:35.045100Z

look what's in the jar

alexmiller 2020-04-08T20:12:56.045500Z

well, first, make sure the jar is on the classpath

alexmiller 2020-04-08T20:13:20.046100Z

second, make sure it has the thing you expect in it (`jar tf ....the.jar`)

paul a 2020-04-08T20:19:21.046700Z

cool, i was unaware of jar tf, i'll give that a shot

2020-04-08T20:22:19.047200Z

also a decent editor can show you what's in a jar and open documents stashed inside it

paul a 2020-04-08T20:33:46.048600Z

whoa, neat

paul a 2020-04-08T20:34:03.049Z

having a visual really helps; i seem to have fixed the problem i was facing

paul a 2020-04-08T20:34:52.049700Z

my thanks to both of you!