How to un-exclude a folder

One of my folders in my PHPStorm installation is stuck in `Excluded` state and I don't know how to fix that. 

When I search for something in my JavaScript code nothing is found. So I was doing an investigation and found out that the whole JS directory is Excluded. When I go to Settings > Directories I see that the Excluded state is on. I can switch this state for other directories. But I cannot change it for my JS directory. It is stuck and I don't know how to undo that. 

And also, if I exclude any other directory, it is added to the list on the right side of this settings. But not my JS directory, it is not there for some reason.

So my question is: How to un-exclude my JS folder so that I can search for code inside it?

I don't know if that is relevant, but I am using PHPStorm v2018.3.1 on Mac

 

8 comments
Comment actions Permalink

Hi, Pavel.
Check the available of excluded directory here

Tools -> Deployment -> Configuration -> Excluded Path

(on Win PHPStorm)

If found, remove it

0
Comment actions Permalink

Hi Aleksandr, thanks for the reply.

The Tools settings doesn't seem to have the Deployment subsection on my PHPStorm: https://d.pr/i/2moTZ0

I found Deployment in Build, but there is no configuration whatsoever: https://d.pr/i/ot9e6z

0
Comment actions Permalink

I have not found the answer there.

Specifically, because your link is talking about deployment. I don't care about deployment and I don't have it even configured as I stated before. 

I want my JS folder to be included in the search.

0
Comment actions Permalink

Then I do not know, maybe the developers will answer

0
Comment actions Permalink

That's probably because of webpack.config file. Check its output: { path: value.

 

1
Comment actions Permalink

Thanks Dmitry. That was my issue. I'm using Webpack in PHPstorm with a WordPress custom theme. Uncommenting the path, which I can't do, removes the Exclude on the theme folder. 

This seems weird only because if I go to change any filenames in the theme folder (refactor > rename) I get a warning from PHPStorm about non-project files. Should the theme folder be excluded just because it's used in Webpack, I'm not clear on what's going on here. I can rename the files, but I feel uneasy about warnings. ;-)

path: path.resolve(__dirname, 'public_html/wp-content/themes/sca/'),
0
Comment actions Permalink

if I go to change any filenames in the theme folder (refactor > rename) I get a warning from PHPStorm about non-project files

The reason for that is that these folder (or its parent) is marked both as excluded and as a library (PHP include / JavaScript library), this makes it a library root and this is why they are considered to be out of the project.

Doesn't un-excluding from the right-click menu work?
https://youtrack.jetbrains.com/issue/WEB-32684#focus=streamItem-27-2857472.0-0

0

Please sign in to leave a comment.