(I should probably rename that so it doesn't conflict with any :dev
alias someone actually has in a project deps.edn
file)
hi, I have a question regarding deps.edn and git dependencies.
Can I build a deps.edn
dependency locally?
I have a project (clj-antlr) that has clojure code + java classes.
Can I make a clj-antlr/deps.edn
so I can use clj-antlr from another project: my-project/deps.edn
? from git ?
My goal is depend on the git version to avoid publishing binary dependenices for clj-antrl.
clj-antlr does have some java classes that need to be compiled in order for it to be used.
Can I trigger a build step in clj-antlr/deps.edn when I use it in my-project/deps.edn
?
@eugen.stan For gitlibs, this only works if you check the compiled Java into source control
which is probably not so nice
for libs that need .class files, I usually make a release to clojars
For sci I have one component which needs this, so I have isolated it into its own mini-library. The rest of sci can be used as a git lib
So there is no life-cycle hooks that I can use in deps.edn
to trigger pre/post processing for dependencies ..
thanks, in my case there are 3 classes so I will make a branch for that and once I am sure all things work I'll publish them.
well, you can also push the compilation phase to the user of the library, as part of the main opts, but so far I haven't seen anyone do this
it's not unreasonable since you can then treat Java as a source-based language as well
I'm hoping tools.build will go a bit into this direction
thanks, I also have some ideas on how to provide this capability. With any luck I will push something this week 🙂 .
Afaik it's possible to compile and load Java code in the JVM process used for development, maybe tools-build will help with that :D
that's what I was suggesting