Would it be possible to get a way to build a gradle plugin using maven (project having chosen maven and building mvn plugin, ant task and gradle plugins is quite common for big projects)?
A need which is not handled today is to create custom archive types (war like typically in my case)
All is doable in build.gradle but it is nicer to just apply a plugin which will replace jar/war by the custom-ar
I was basically blocked on the fact Jar and War classes were in gradle-plugins.
It’s not a supported feature, and although nothing is preventing you from downloading the Gradle distribution and putting the Gradle Jars on Maven’s compile class path, I wouldn’t recommend it.
I don’t understand your other statements, so I can’t comment on them.
What prevent me to use local path is the fact the project should build without local setup excepted maven. There are hacks but it doesn’t worth going these ways and waiting a later gradle release is acceptable (this is not feature we need in the next month).
Basically the plugin would be exactly the war one excepted it would build a bar (dedicated to batch) instead of a war.
My first throuht was to copy war plugin but this one is not in a deployed api jar.
Can you comment on the why you can’t deploy the gradle libraries to central? What’s the actual problem with this? I am building a plugin that should work with both gradle and maven. Most of the code is actually shared between the two
It would be fairly natural for me to build the whole project with a single command but I just can’t. I agree that Maven does not support building plugins with Gradle but on the other hand my plugin is a jar file with a single class. That’s a bit frustrating that the only limitation is that you guys don’t push your librairies to central.
They don’t usually get to read/reply here, as they already have too many other things on their schedule. If you absolutely want to know their reasons, perhaps try to contact them directly.
Gradle plugins are just “jars” now, but this is going to change relatively soon and we always knew this was coming.
Plugins are soon going to have their own metadata and possibly a non standard bootstrapping mechanism to support classloader isolation. We aren’t likely to ever invest in custom Maven tooling that supports the same thing. Just publishing the JARs would not be enough going forward.