MyNixOS website logo

Configuration written to $XDG_CONFIG_HOME/opencode/opencode.json. See https://opencode.ai/docs/config/ for the documentation.

Attribute sets containing ordered lib.hm.dag.entryBefore or lib.hm.dag.entryAfter values are rendered in topological order, with raw sibling values treated as unordered entries. This is useful for OpenCode permission rules, where the last matching rule wins.

The plugin key accepts a list of plugin references: local paths to plugin directories or files, derivations (e.g. fetchFromGitHub), string paths into derivations, or names of external plugins fetched and built by OpenCode.

Note, "$schema": "https://opencode.ai/config.json" is automatically added to the configuration.

Declarations
Type
JSON value
Default
{ }
Example
{
  autoshare = false;
  autoupdate = true;
  model = "anthropic/claude-sonnet-4-20250514";
}