I am trying to make it so I can create a version of my java program where a paid flag is on in one build, and a free flag is on in the other using kotlin gradle.
I have tried to do this so far by splitting most of my program into a common subrepo, and then creating two new repos paid and free. Ideally, I want to be able to compile free and have it include all the contents of common in the resulting jar (including its libraries) as well as have the class I have defined in free override the corresponding class in common. (this has had various failed results, due to not including all the contents in the jar)
Any help would be much appreciated.