custom

fun custom(className: String)(source)

Registers a user-defined com.aalekh.aalekh.analysis.rules.ArchRule implementation by its fully qualified class name.

aalekh {
rules {
custom("com.example.NoAndroidInDomainRule")
}
}

The class must implement com.aalekh.aalekh.analysis.rules.ArchRule, expose a no-argument public constructor, and be reachable from the plugin's runtime classpath. Place the rule class in a module that the consumer adds to the settings (or root project) buildscript { dependencies { classpath(...) } } block, or in an includeBuild composite project alongside the plugin.

If the class cannot be loaded or instantiated, aalekhCheck surfaces an ERROR violation with the underlying cause rather than crashing the build.