anomalyco / anomalyco/opencode
Bug: rg.exe hangs when running from home directory (Windows) - scans millions of files
Open
@Hona is already working on this.
Since Aug 9, 2026.
- Dominant language
- TypeScript
- Stars
- 209k
- Forks
- 27.5k
- PR merge metrics
- PR metrics pending
Description
Description
When running opencode from the home directory on Windows, rg.exe scans ALL files in the home directory (including AppData, node_modules, go/pkg, etc.), consuming 95%+ CPU and 1GB+ RAM, making the system completely unresponsive.
This started after v1.17.2 when the default changed to use ripgreplayer on Windows instead of fff.
Steps to Reproduce
- Open PowerShell on Windows
- Run opencode from home directory (C:\Users<username>)
- rg.exe starts scanning millions of files
- System becomes unresponsive
Expected Behavior
opencode should skip heavy directories (AppData, node_modules, go, .cache, etc.) by default, or limit scan depth when not in a git repository.
Actual Behavior
rg.exe runs --no-config --files --glob=!.git/* which scans EVERYTHING.
Environment
- OS: Windows 11
- opencode version: v1.18.15
- rg version: 14.1.1
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.