Skip to content

Speed up the "find the app" search - #10

Merged
Former-Stranger merged 1 commit into
mainfrom
faster-app-search
Oct 27, 2026
Merged

Former-Stranger merged 1 commit into
mainfrom
faster-app-search

Conversation

@Former-Stranger

Copy link
Copy Markdown
Owner

What does this change?

The app search in Find the app on the client used grep -r, which reads every byte of every file in a single process. On a real Mac (63 GB under /Applications and ~/Library/Application Support, including a 10 GB VM disk image) it ran for well over 10 minutes.

  • macOS and Linux: find … -type f -size -1024M -print0 | xargs -0 -n 200 -P 8 grep -l --binary-files=text -F '<name>'. This skips files over 1 GB and runs 8 greps at a time.
  • Windows: adds Where-Object Length -lt 1GB before Select-String.
  • The labels now say the search skips files over 1 GB.

App frameworks of several hundred MB, such as browser frameworks, Electron app.asar files and Qt WebEngine, are still searched.

How was it tested?

  • macOS: the new command took about 2 minutes on the same Mac and found the same files as the old one.
  • Windows: the command parses.
  • Linux: a full run on an Ubuntu host took 140 s.
  • terraform test (not affected)

Checklist

  • Docs and CHANGELOG.md (Unreleased) updated where users would notice
  • No real hostnames, IPs, tenant IDs, keys or logs in code, tests or this PR

🤖 Generated with Claude Code

A plain recursive grep read every byte of every file in one process: on a
Mac with 63 GB under /Applications and Application Support, including a
10 GB VM disk image, it ran for well over 10 minutes. The macOS and Linux
commands now skip files over 1 GB and run 8 greps in parallel via
find | xargs -P (about 2 minutes on the same Mac, same results); the
Windows command skips files over 1 GB too.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@Former-Stranger
Former-Stranger merged commit 3112e34 into main Oct 27, 2026
9 checks passed
@Former-Stranger
Former-Stranger deleted the faster-app-search branch October 27, 2026 17:52
@Former-Stranger Former-Stranger mentioned this pull request Oct 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant