0

I want to create a Gradle plugin to simplify the creation of the project for Spigot plugin using mappings, I already have all the necessary tasks, however I do not know how to do that when applying the plugin to the project to add remapped-mojang dependency from mavenLocal() and if it has not yet been created then execute the task of launching BuildTools first

I tried adding add dependency addition to doLast, but it didn't work. I want to know if this is possible, and also how I can run a task when adding a plugin to a project

  • Overall what you're asking is quite broad, but I believe the thrust of it is "I have a plugin that's dependent on a constantly evolving source, and want to ensure compatibility with multiple source versions simultaneously", correct? If so, a common approach is to abstract the functionality you need from that project, and to have modules/implementations of that abstract per version that you can dynamically load. – Rogue Aug 14 '23 at 16:07
  • I already have the necessary tasks to download BuildTools and run it depending on the version specified in the extension, but I don't know how to add to the project dependencies the jar file resulting from running BuildTools – Maks Ternovoy Aug 14 '23 at 16:19

0 Answers0