Cannot apply custom plugin

I’m not 100% sure, but you’ve probably published a jar into your local .m2 repository that doesn’t have the appropriate plugin properties file in the jar.

If you run gradle buildEnvironment (without applying your plugin), do you see your plugin listed as a dependency? If so, you’re adding the dependency correctly and there’s something wrong with the jar Gradle is trying to use.

I wouldn’t try to use mavenLocal() to try out your new plugin. TestKit tests are best at capturing/describing the behavior you want your plugin to have, but for something quick and dirty to try things out, I would suggest to use a composite build. This will make sure you’re using the latest and greatest version of your plugin without going through a manual publishing step.

You would keep what you have in your buildscript {} block and apply the plugin as foo.bar.some-thing.plugin. When you want to try your plugin after making changes to it, you would use:

gradle tasks --include-build path/to/plugin_project

There are some more focused Plugin development guides at https://guides.gradle.org that might provide you more clues.