Activate Java 9 features
Answered
Hi,
somehow a stupid question as I thought all Java 9 features would be activate by default.
I want to try out Java 9, and I wanted to create a new module, but the "New | module-info.java" is not showing up in the menu. I'm running IntelliJ IDEA Version 2017.2.5.
Do I have to activate anything?
Best regards,
Andreas

Please sign in to leave a comment.
Make sure you have specified version 9 of JDK for project and set 9 language level for modules or project. Then from the source folder context menu the option should be available, see Getting Started with Java 9 Module System tutorial as an example.
Yes, sure I did that before. That's why I'm so confused it doesn't show up.
In fact the Java9 support is there, i.e. when I create a module-info.java manually it offers code completion right away. I'm just confused creating module-info.java is not offered under "new"
From the 1st screenshot it doesn't look like you invoke "New file" action for the Java module type (there is no Java class option at all). Make sure you have created new module of a Java type.
Note that the menu is context-sensitive (different options are shown based on the place where you invoke the action).
Many thanks! I was aware of the context sensitivity, but somehow I defined src/main/java as the source folder, not src directly. Thus, it didn't show up, when I right-clicked src. Now I've realized the blue folder and when I right-click this folder module-info.java shows up. So problem was once again in front of the screen :)