fix: grep and glob tools usage without path param under Opencode Desktop#1393
Merged
code-yeongyu merged 1 commit intocode-yeongyu:devfrom Feb 4, 2026
Merged
fix: grep and glob tools usage without path param under Opencode Desktop#1393code-yeongyu merged 1 commit intocode-yeongyu:devfrom
code-yeongyu merged 1 commit intocode-yeongyu:devfrom
Conversation
…ectory. OpenCode Desktop might not send path as a param and cwd might resolve to "/"
Contributor
|
All contributors have signed the CLA. Thank you! ✅ |
Contributor
Author
|
I have read the CLA Document and I hereby sign the CLA |
leoisadev1
pushed a commit
to leoisadev1/oh-my-opencode
that referenced
this pull request
Feb 3, 2026
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.
Fixes grep and glob tools usage without path param under Opencode Desktop
Summary
Grep and Glob now uses ctx.directory when no path data is given. In OpenCode Desktop, the cwd is "/" when run via Finder or Dock, this causes the tools to run under "/" instead of the project directory. This small change fixes the problem as opencode pushed changes so that ctx receives the correct directory now (via Instance.directory)
Related Issues
#658
#588
-- also probably from opencode
anomalyco/opencode#7143
Summary by cubic
Fixes grep and glob running under “/” in OpenCode Desktop by defaulting the search path to ctx.directory when no path is provided. Searches now run in the project directory even when Desktop launches with cwd set to “/”.
Written for commit 527c21e. Summary will update on new commits.