Adding a configuration directory to the plugins classpath

I think I’ve finally managed to resolve this by wrapping my configuration file inside its own Gradle plugin. This allows me to perform :sparkles: magic :sparkles: like this:

project.getPluginManager().withPlugin(plug -> {
    Class<? extends Plugin> pluginClass = project.getPlugins().getPlugin(plug.getId()).getClass();
    loadConfig(pluginClass.getResourceAsStream("config.properties"));
});

provided my new plugin’s Plugin implementation lives in the same package as its configuration file.