Filter search result

I can not say the file search result is always usable.

  1. Here an exemple where there is an exact result but is not the first result.In my exemple I can found the exact result because there is so much scroll needed to get it.
    Why the exact result is not the first ?

  2. Why the main folder (the folder added to the explorer and workspace) didn’t work here too ?
    If I have the structure like this in my explorer, I can not search for " addon1/file1.txt " there is no result but " file1.txt " have two result.
    addon1/
    |_file1.txt
    addon2/
    |_file1.txt

Combining the 1. and 2. make the file search very unusable in some case.

@Al thank you for the discussion!

Why the exact result is not the first ?

I cannot see the full-list to identify what the exact result would be in this case, but it looks like the search term is not exact hence why you are getting fuzzy matches. (perhaps libs/modules/activityLog.php would be the exact search term).

Why the main folder (the folder added to the explorer and workspace) didn’t work here too ?

In your example it looks like you are actually using a multi-root workspace (a workspace with more than one actual root - denoted by a workspace file). It is possible you are experiencing some limitations with a multi-root workspace while searching such as https://github.com/eclipse-theia/theia/issues/6641.

Additional Information:

  • which version of the theia framework are you using?
  • would you be able to share you workspace for test purposes?

Yes thoses results are fuzzy matches, the « libs/modules/activityLog.php » is an exact match.
This is exactly the issue you mention at and exactly https://github.com/eclipse-theia/theia/issues/5636 too.

In multi-root workspace with many version of the same code base we can easily :

  • Open a file.
  • Copy relative path of it.
  • CTRL + P + paste the relative path.
  • Find the same file in the other root (in the other version).
  • Make a diff between them for example.

I’m running on 1.12. I cannont update actuality due to dependencies problem remaining to libc not fresh enough. (debian 7), upgrade to debian 11 is planned.

I’m also working in multi-root workspace for many workspaces for two main reason :

  • loading many version of the same code base at the same time.
  • some folder I working on the same project are not in the same root folder and loading the first common ancestor will load way too much files in the workspace.

In the issue https://github.com/eclipse-theia/theia/issues/6641 look likes the same problem as mine.
multi-root is not well handed.

Taking my previous exemple en open the two files (file1.txt). Once opened, you absolutely can’t tell which one is which in the editor.

  • The mouse tooltip over the tab trim the root in the path.
  • The « auto reveal » option in explorer did not help in large folder because we can’t see the root in the view. We need to scroll to find the root and this many times occurs to humans errors.
  • The Edit > Copy Path and past it somewhere can help but this is not handy mainly because we can not open an editor without save the file (like in sublime text for example).

I can tell you that adding et new root does not appear in the explorer, we are forced to refresh the whole theia page (working in web mode) to view the new root in the explorer. Same thing for removing a root.

If you really need a workspace to work at, I can make you a exemple but I can’t share my current workspace.

Thank you your help and taking time understanding my needs.

I’m running on 1.12. I cannont update actuality due to dependencies problem remaining to libc not fresh enough. (debian 7), upgrade to debian 11 is planned.

No problem, just that 1.12 is quite old now and a lot of improvements were made especially to fuzzy searching.

Taking my previous exemple en open the two files (file1.txt). Once opened, you absolutely can’t tell which one is which in the editor.

I think this would be an improvement for sure, if two files exist with the same name in different roots we should try to help, much like when two files exist with the same name in the same root:

image

  • The mouse tooltip over the tab trim the root in the path.

Another great find, I believe the full-path should be displayed in such a case.

I can tell you that adding et new root does not appear in the explorer, we are forced to refresh the whole theia page (working in web mode) to view the new root in the explorer. Same thing for removing a root.

This does not happen with newer theia, at least not when I tested.

Great to learn that newer version already adress some of theses problems.

I think this would be an improvement for sure, if two files exist with the same name in different roots we should try to help, much like when two files exist with the same name in the same root:

For sure, I think it’s very achievable to add de root folder name to the path displayed in some places when multi-root is used.
It’s quite conveniant to not display the root folder when just one root is used.