Module setup for a single source base with incompatible version changes

Hi folks,

Is it possible, using the IDEA project structure to have a single project code line that has a few incompatible changes between versions?

Here's what I mean:  The intellij-haxe plugin code base supports version 13.x, 14.0, and 14.1.  They each have minor incompatible changes that make it so that the sources cannot be made to compile just by adding new apis.  Currently, these are supported via separate branches, but that is tedious.  So, what we would like to do is separate out only the changed files into parallel source directories, and only include one or the other depending upon the target build.  Something like this:

Current structure:

New Structure:

We've been trying to set up modules for each target version, but, of course, you cannot have modules with the same source root.  So we need a (multiple?) module setup that allows us to have target output for each version, and that we don't have to manually change the project for each compile/test path.  (For example, we would like to build "intellij-haxe-13" and "intellij-haxe-14.0" as separate targets.)

Also, just abandoning older versions as each new one emerges is not only bad practice but it is impractical for enterprises that have multiple projects that need stable development environments.  In short, it's not an option.

Thanks for any help!


P.S. Doing all of this in ant is trivial, and we have that.  It would be nice to continue to use Idea's native make and integrated Junit test framework, (run single failing tests, filter output to failures, etc.) but that can't be done using an ant task -- at least as far as I can tell.  EB

1 comment
Comment actions Permalink

We can only recommend to have different VCS branches for the supported haxe versions.


Please sign in to leave a comment.