> Exception thrown while executing model rule: MyRules#appBinaries > create(main)
> Cannot create a 'org.gradle.platform.base.ApplicationSpec' because this type is not known to components. Known types are: (None)
if I change from ApplicationBinarySpec to just BinarySpec it works. Maybe I got it wrong but I thought when I define a custom ApplicationSpec the binary part should be of ApplicationBinarySpec.
In 2.11 you need to register both the component type (TheApp) and binary type (TheAppBinary). You do this using methods on the RuleSource. Take a look at the customModel/componentType sample in the Gradle distribution for an example of how to do this.
Exception thrown while executing model rule: MyRules#appBinaries > create(main)
Cannot create a ‘org.gradle.platform.base.ApplicationSpec’ because this type is not known to components. Known types are: TheApp