Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Changing Grails SDK in IntelliJ IDEA Doesn't Work on Plugin Modules

IDEA 11.1.2

I have a Grails app I need to upgrade. The application consists of several modules. One being the application and a few others being plugins. I right clicked on the application and went to Grails -> Change SDK Version. I chose the version I wanted, then IDEA asked me if I wanted to upgrade the application. Clicked yes and all was good.

I've been trying to do the same thing on the plugin modules. IDEA never asks if I want to upgrade and it doesn't appear to change the SDK. If I upgrade the modules from the command line, when I come back to IDEA, it thinks there is a version mismatch and automatically downgrades me without even asking.

Is there a workaround for this?

like image 742
Gregg Avatar asked Jul 17 '12 14:07

Gregg


2 Answers

It worked for me in this IDEA version. Make sure that you change Grails version in application.properties of all plugins:

app.grails.version=2.1.0

Then right-click on every module (plugin), Grails, Change SDK version. It should be changed already.

like image 148
Tomasz Kalkosiński Avatar answered Sep 26 '22 09:09

Tomasz Kalkosiński


Have exactly same problem - app + plugins wich requires different SDK (for testing).

After some investigation found that it's an IntelliJ IDEA bug IDEA-114418. So, I think, it will be good if you'll vote for this bug there too.

like image 44
Igor Artamonov Avatar answered Sep 24 '22 09:09

Igor Artamonov