Prevent folder from being indexed

Answered

I'm trying to stop Rider indexing files from a /dist folder. This folder is not included in any project, but it is being constantly re-indexed anyway.

I tried adding an entry to Editor > Inspection Settings > Elements to skip > Files and Folders (like in this screenshot) but I can still see the files being indexed in the the Background Tasks list at the bottom of the screen.

At this point, Rider is pretty much unusuable for me due to the amount of CPU it's requiring.

How do I prevent my /dist folder from being indexed?

 

 

5
46 comments
Avatar
Permanently deleted user

Still doesn't work in Rider 2018.3 EAP. Is it really that hard to implement exclude function properly? It is over a year since the issue was reported.

0

Yannick le RestifKrzysztof Wojcicki

Could you please check if the node_molules folder is marked as `no index` in FileSystem view of the Explorer?

0
Avatar
Permanently deleted user

It is not marked with no_index, and I don't see any way to change it.

0

@julia: yes, they are.

@krzysztof: right click/tools/stop index

0
Avatar
Permanently deleted user

Please show me this option then:

0

Yannick le RestifKrzysztof Wojcicki

We've turned off "Stop index" feature for node_modules folder in Rider 2018.3. Now it is marked as library root the same as in WebStorm. Rider is supposed to index only @types folder and all the packages from package.json. The main point is to index the top-level packages only and do not index their own dependencies. Indexing is required to build a valid completion/navigation from/to these packages. If Rider is indexing anything else from your node_modules folder, please let me know.

If you'd like to disable indexing for all npm packages you need to disable the node_modules folder in "Settings | Languages & Frameworks | JavaScript | Libraries". Note, that @types folder will be indexed anyway.

Hope this helps!

0

Thanks for that explanation. I'm still using Rider 2018.2 but I'll let you know how Rider 2018.3 works for me when I install it.

1
Avatar
Permanently deleted user

As I said earlier, it doesn't work.

0

Krzysztof Wojcicki,

Do you mean that disabling the node_modules folder in "Settings | Languages & Frameworks | JavaScript | Libraries" doesn't help? Please try File/Invalidate caches/restart after saving settings.

0
Avatar
Permanently deleted user

It's 2019 and PHPStorm still indexes excluded directories. Invalidate caches/restart does not work. There is not "node_modules" folder in Javascript | Libraries.

0

P Kochan,

Do you mean Rider, not PhpStorm? Could you please attach a screenshot of the Explorer tool window with the view set to FileSystem?

0
Avatar
Permanently deleted user

hey,

i need this specific folder (.next) not to be indexed. it's not  a library.

It's a server-side rendered site that's rebuilt every time I save a file, causing quite a lot of CPU consumption.

How can i prevent it from being indexed?

0

Hi!

To stop indexing for a folder

1. right-click on a folder -> exclude
2. click "Show All Files" in the Solution Explorer toolbar 


3. Find your excluded folder 
4. Right-click on it -> Tools -> Stop Index

0

Still doesn't work. Version: 2019.2 #RD-192.5895.1069

0

Hello,

Thank you for reporting the problem. I've created an issue. Please enable trace scenario "ProjectModel", then reproduce the problem and share all Rider logs by attaching to the issue on Youtrack.

1

Right click project, specific folder or file

1. Tools 

2. Stop Index

 

This worked for me

2

Please sign in to leave a comment.