Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can't see project folders in IntelliJ IDEA

Every once in a while, I open an old project and I can't see any of the folders in the intelliJ project viewer. I can see all the files at the root.. but no folders. Yes I can delete the .iml file and .idea folder and re-create the project, but come on.. there's gotta be an easier way to fix this.

Is there?

like image 536
B T Avatar asked Feb 06 '15 05:02

B T


People also ask

Why project Structure is not showing in IntelliJ?

Restart IntelliJ. Verified that the project root folder now appeared (in Project Settings > Modules) Toggle On the toolbar buttons (i.e. 1. Project Structure) to display on the left sidebar (clicked View > Toolbar Buttons until tick appears)

Where is my project in IntelliJ IDEA?

Open the project using the . ipr file: from the main menu, select File | Open and select the . ipr in the folder with the project that you want to convert. When the project has opened, from the main menu, select File | Manage IDE Settings | Save as Directory-Based Format.


3 Answers

If you look in project settings (ctrl-shift-alt-s), you should see a module structure. If you instead see "Nothing to see", do the following:

  1. In Project Structure -> Modules, press the + button,
  2. press enter (since, for some weird reason, it won't let me click on "New Module")
  3. In the window that pops up, click on the "..." next to Content root, find your root folder, and select it
  4. Press ok
  5. ignore any warning that says the name is already in use (or to that effect)
like image 73
vikingsteve Avatar answered Oct 20 '22 03:10

vikingsteve


the simplest solution worked from me, just delete the .idea folder

keep in mind this will delete all of idea's current project configuration, it'll create the folder with default settings when reload the project again... but all other configuration will be lost if not properly backed-up

like image 78
shahaf Avatar answered Oct 20 '22 03:10

shahaf


It might be because the project didn't have any modules defined. Try adding existing source code by hitting File > New > Module from Existing Sources and select the parent directory of the project for source code

Module from existing sources

like image 40
Harish Gokavarapu Avatar answered Oct 20 '22 04:10

Harish Gokavarapu