-
Notifications
You must be signed in to change notification settings - Fork 14.9k
[Bug] Global commands/ directory not recognized on Windows, only command/ works #9335
Copy link
Copy link
Closed
Labels
opentuiThis relates to changes in v1.0, now that opencode uses opentuiThis relates to changes in v1.0, now that opencode uses opentuiwindows
Description
Description
On Windows, custom commands placed in the global config directory ~/.config/opencode/commands/ are not recognized. However, renaming the directory to command/ (singular) makes it work correctly.
Expected Behavior
According to the source code in packages/opencode/src/config/config.ts:
const COMMAND_GLOB = new Bun.Glob("{command,commands}/**/*.md")
Both command/ and commands/ should be valid directory names.
Actual Behavior
- ~/.config/opencode/commands/commit.md → Not recognized (command not shown in / menu)
- ~/.config/opencode/command/commit.md → Works correctly
Environment - OS: Windows 11
- OpenCode Version: 1.1.25
- Shell: Git Bash / PowerShell
Possible Cause
The {command,commands} glob pattern in Bun.Glob may not work correctly on Windows, possibly d
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
opentuiThis relates to changes in v1.0, now that opencode uses opentuiThis relates to changes in v1.0, now that opencode uses opentuiwindows