Skip to content

feat: detect and resolve jsonc file over json for opencode config - #10

Open
IdrisGit wants to merge 2 commits into
glommer:mainfrom
IdrisGit:opencode-jsonc-support
Open

feat: detect and resolve jsonc file over json for opencode config#10
IdrisGit wants to merge 2 commits into
glommer:mainfrom
IdrisGit:opencode-jsonc-support

Conversation

@IdrisGit

@IdrisGit IdrisGit commented Aug 8, 2026

Copy link
Copy Markdown
Contributor

OpenCode supports and prefers opencode.jsonc over opencode.json, OpenCode config docs

currently the cli's init command completely ignores opencode.jsonc file and creates a new opencode.json file, this PR updates the preference order to check for existing jsonc config over json, if both are not found it will create the jsonc config file.

introduces jsonc-parser for jsonc handling, maintained by Microsoft and used by OpenCode itself.

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