When I search for files using the GNOME search bar, I get incomplete results. When I click on “Files” next to the search results, Nautilus opens and the same incomplete results are shown. However, when I open Nautilus directly and search for the file, the file I am looking for is found immediately. The same is true for the “locate” command.
The file I am looking for is in a subfolder of /home/$USER/nextcloud and other files in some subfolders come up in the search results.
I was researching ways to reset/recreate the search index, but I could not find anything recent and/or helpful.
File indexing via Tracker (name recently switched to TinySPARQL) only takes place for the default or user-set paths. In case you haven’t done so explicitly, the ~/nextcloud subdirectory should not be indexed.
You can add that subdirectory to the list of search paths by going to GNOME Settings → Search → Search locations → Custom locations. Wait for a while for the new location to get indexed.
Because I find it a lot more convenient to use a centralized search functionality (simply click Super) and I do not care about the index being up to date - if it is refreshed every day or so, I would be fine with that.
I found some information on those paths, so I checked. Although the Nextcloud folder was already being indexed (because of bookmarks), I also added it manually, but the result is the same. Some files under ~/nextcloud show up, while others do not…