> clojure -X:depstar sync-pom compile jar
If I wanted to add a prepare-assets
step? How would that fit in? Is it like writing any other clojure function, or would it be like writing a depstar plugin? How likely is it that an idiomatic clojure function would also function as a cli target?
One of the reasons automating git is a pain is that there 1) a low level programmatic library and 2) a high level command line interface and not much in between. Maybe there's no way around it, but it seems like it's easy to fall into the trap where the cli is the primary interface and the programmatic interface becomes less idiomatic. It's a tough problem to crack since the clojure cli wants to tame the bashisms, clojurisms, and javaisms with just the right isms on top.
I’ll try to choose the hash map contents/keys carefully but it would be just writing a function that took a hash map and return a hash map and then making sure it’s on the classpath. Some of it would depend on what inputs your prepare-assets
function needed?
I think having a task that computes the project basis (possible based on aliases provided as :exec-args
) and then passes that through the pipeline would be helpful.
I think we may all get a better sense of how this should work once we see tools.build
— I suspect it will have a few “utility” tasks that standardize some of this setup. @alexmiller has indicate that tools.build
will have a number of “standard” build steps built-in so it’ll be a case of other tools following that lead and building on the basic pipeline.
depstar
does a lot of “smart” stuff when building uberjar files (in terms of merging things) so once I have tools.build
to play with, I’ll figure out how to make the “smart” part of depstar
replace the (presumably, much simpler) uber
/`jar` tasks.
There will be a basis building function. Well, there are multiple atm, I’m trying to sort all that out :)
Yeah, we should probably do that for you
Thank you, yeah, that would be super-helpful!