Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Cannot add framework support in IntelliJ 14 Ultimate

I found a pretty old post with this question but unfortunately he didn't get any help. I hope someone can assist me.

I created a repo at GitHub. After cloning it to my computer I tried to add the following framework support: Maven, JSF, EJB, CDI, etc. I know I could add the files manually. But, I want to use what the IDE has to offer.

However, the only framework showing up is SQL, which is different from this post from stackoverflow and from their documentation. enter image description here Has anyone had this same problem and got it working?

like image 364
Sidney de Moraes Avatar asked Dec 17 '15 15:12

Sidney de Moraes


People also ask

How do I add framework support in IntelliJ?

In the Project tool window Alt+1 , right-click the module to which you want to add a facet, and select Add Framework Support. Select the necessary framework from the list. Depending on your choice, you might be prompted to configure additional settings (for example, to configure a library).

How do I add Spring framework to IntelliJ?

Enable Spring support in IntelliJ IDEAPress Ctrl+Alt+S to open the IDE settings and select Plugins. Open the Installed tab, search for Spring and make sure that the checkboxes next to all relevant plugins are selected.

How do I add an existing module to IntelliJ?

Import an existing moduleFrom the main menu, select File | New | Module from Existing Sources. In the dialog that opens, specify the path the . iml file of the module that you want to import, and click Open. By doing so, you are attaching another module to the project without physically moving any files.


2 Answers

Intellij reacts to changes in your Maven pom.xml file. Maven does not react to changes in your IntelliJ project module settings.

The steps that you should follow here are

  1. Close IntelliJ
  2. In a command shell, clone your Github repository.
  3. Using an editor external to IntelliJ such as VI or Notepad, create a pom.xml in the root directory. Better yet, use a Maven Archetype to generate your pom.xml.
  4. Now open IntelliJ. Choose File, New, Project From Existing Sources. Navigate to your pom.xml and follow the prompts.
  5. I recommend checking Search for projects recursively and Import Maven projects automatically.enter image description here
  6. Finish the project creation.
  7. Now, add dependencies to your pom.xml via the dependencies tag. See Maven Dependencies. Intellij will automatically react to dependencies that you add as long as it can see a Maven Repository on your local machine or on your network or on the Internet.
like image 81
Kirby Avatar answered Sep 20 '22 07:09

Kirby


I know it is a little bit to late but I just post it because it is still an possible issue: You need to open YourProjectName.iml and make sure that the type (<module type="JAVA_MODULE" version="4">) is JAVA_MODULE and not something else!(In my case it was WEB_MODULE)

like image 40
Berstanio Avatar answered Sep 18 '22 07:09

Berstanio