readme.md and Documents~ directory in root of Unity project are not indexed

Hi,

This has been bugging me for a long time (and spans multiple Rider versions), the readme.md file and the Documents~ directory located in the root of my Unity project are not being indexed.

The only way I can get them to index is to right-click the files in the file explorer panel and to force them to index. But that is not a permanent solution as it will often revert back to being non-indexed.
Or to edit files I have to manually open them from the file explorer panel.

How do I get them to index automatically so I can use the default search functionality to view or edit the content of these files?

Thanks in advance.

1
2 comments

Hello,

Currently for Unity solutions only Assets folder is indexed by default. You can use Directory.Build.props file in the project root to include custom files and folders into an assembly - that way they will be indexed, albeit still not visible in the Unity view of the Explorer window, only in the Solution view. An example of the props file:

<Project>
<ItemGroup Condition="$(AssemblyName) == 'Assembly-CSharp'">
<Content Include="README.md"/>
<Content Include="Documents~\**"/>
</ItemGroup>
</Project>

And thank you for the feedback, we really appreciate it. I have passed it on to the relevant team and we will take it into account when planning changes for the upcoming releases.

1

Thank you for the clear explanation! I was unaware you could use a Directory.Build.props file for this. Works for me.

Cheers

0

Please sign in to leave a comment.