This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2016-05-06
Channels
- # admin-announcements (6)
- # beginners (147)
- # boot (9)
- # braveandtrue (5)
- # cider (11)
- # cljsjs (1)
- # cljsrn (4)
- # clojure (82)
- # clojure-greece (9)
- # clojure-poland (9)
- # clojure-russia (288)
- # clojure-taiwan (2)
- # clojure-uk (73)
- # clojurescript (123)
- # consulting (3)
- # cursive (26)
- # datascript (4)
- # datomic (32)
- # dirac (56)
- # emacs (11)
- # flambo (2)
- # hoplon (425)
- # jobs-rus (1)
- # lein-figwheel (3)
- # leiningen (16)
- # luminus (42)
- # mount (7)
- # om (1)
- # om-next (2)
- # onyx (8)
- # other-languages (146)
- # quil (3)
- # re-frame (17)
- # reagent (6)
- # spacemacs (2)
- # uncomplicate (8)
- # untangled (71)
- # vim (2)
- # yada (49)
I'm trying to write a plugin that uses lucene, but it seems that leiningen already includes a version of lucene. How do I avoid these dependency conflicts in a plugin and use my intended version?
@vipaca not sure if you can, Leiningen is distributed as an uberjar, and I don’t think you can put stuff ahead of it on the classpath (and that might be a bad idea)
https://github.com/benedekfazekas/mranderson might be what you need
Looks like https://github.com/jaley/cloc does this by using leiningen.core.eval/eval-in-project
except not in the invoking project, but rather a project of its own with cloc as the only dependency.
In that way its grabs invoking project's details then isolates from that project and leiningen via separate subprocess.
Oh forgot Lucene is Java. You could use Maven Shade to do the same thing there
Or maybe mranderson supports Java too, not sure
I was thinking that mranderson would be good for what https://github.com/jonase/eastwood ends up doing which is very simliar.
is there any way to specify where or how extra files are to be added to a jar? :filespecs
is close to what i want but it's off in that if i say {:type :paths ["foo/" "bar/"]}
instead of adding foo/
and bar/
it adds the contents of foo/
and bar/
to the root of the jar. what i want is to say put foo/
and bar/
at the root of the jar.
@noprompt: I would add a lein alias command for packaging jar and there I would do a bash script which would copy contents in the way and shape as needed and then call jar task operating on that dir as :source-paths
or something along those lines
also somewhat related hint: to override/wrap “standard” lein task, with a shell script which then calls back to perform standard implementation, I use this trick in profiles:
https://github.com/binaryage/dirac/blob/9fbc3ebb142307e2d527ca496b96ed768e0e1641/project.clj#L338
then I can freely override for example “jar” task with my own alias, and call back original via lein with-profile +nuke-aliases jar
ugly, but does the job