Running ‘gradle idea’ from command line reverts back to old Scala facets in IntelliJ IDEA 14

When gradle is executed from command line outside of IDEA and when IDEA restarts all Scala modules earlier converted from facets to SDKs will be reverted back to facets.

See this post about recent changes in the Scala IDEA plugin:

“Another change is that we’ve finally decided to get rid of the Scala facet and replace it with so called Scala SDK library”

I’ve come up with a few tedious workarounds which all of them involves removing cached files.

Software versions: Gradle: 2.2 IntelliJ IDEA: 14.0.2 Scala plugin: 1.1.3 Platform: Win 8.1 Pro 64-bit, Mac OS X 10.10.1

This is a multi-project build with a mixture of java and scala projects.

The first time after running the cleanIdea task and with an empty out folder you are prompted with this:

Running it a second time after the conversion taking place you end up in this state:

Hmm, I think this is a change we’d have to make in the way we generate the project files to support Intellij IDEA 14.

I created GRADLE-3276 for tracking. You might be able to work around it by munging the generated files, but I haven’t looked deeply.

What will make this issue interesting enough to look closer at?

it’s not really about interest, but cost of fixing vs. cost of not fixing as we have limited time budgets.

So, your options are to raise the cost of not fixing (e.g. create more complaints about this by more users) or reduce the cost of fixing (e.g. propose a solution and/or supply a fix by way of contribution).

I just submitted can you guys please have a look?