feat(files): move workspace indexing and search to native for saf/files#2529
Open
bajrangCoder wants to merge 2 commits into
Open
feat(files): move workspace indexing and search to native for saf/files#2529bajrangCoder wants to merge 2 commits into
bajrangCoder wants to merge 2 commits into
Conversation
bajrangCoder
marked this pull request as ready for review
July 23, 2026 14:11
Contributor
Greptile SummaryThis PR moves local workspace indexing and search into the Android native layer. The main changes are:
Confidence Score: 5/5This looks safe to merge.
Important Files Changed
Flowchart%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[Open workspace] --> B{Native indexing supported?}
B -->|SAF or file URL| C[Native workspace scan]
C --> D[(SQLite index)]
B -->|Remote or custom provider| E[JavaScript file tree]
F[Quick Open] --> G[Native filename query]
G --> D
H[Project search] --> I[Native root search]
I --> D
I --> J[Batched result events]
E --> K[JavaScript search fallback]
Reviews (1): Last reviewed commit: "fix batch stuff" | Re-trigger Greptile |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Moves file indexing and project-wide search for SAF and
file://workspaces to the Android native layer.This prevents large workspaces, such as Termux home, from creating a complete file tree in the WebView.
Changes
fileIndexplugin API.node_modules.~/storage.Breaking changes
acode.require("fileList")is deprecated.It now contains files from non-native providers only. Plugins using it for SAF or
file://workspaces must migrate to:Differences from
fileList:fileIndexis asynchronous.Treeobjects.search-resultsevents.The native index database version is also updated. Existing generated indexes will be rebuilt automatically.
Compatibility
file://: native index and search.sdcard.workspaceSearch()keeps single-result events unlessbatchResults: trueis provided.