programs.opencode.skills

Custom agent skills for opencode.

This option can either be:

If an attribute set is used, the attribute name becomes the skill directory name, and the value is either:

This also accepts Nix store paths (e.g., source from a package), allowing you to reference subdirectories within a package source.

If a path is used, it is expected to contain one folder per skill name, each containing a SKILL.md. The directory is symlinked to $XDG_CONFIG_HOME/opencode/skill/.

See https://opencode.ai/docs/skills/ for the documentation.

Type
(attribute set of (strings concatenated with "\n" or absolute path or string)) or absolute path
Default
{ }
Example
{
  git-release = ''
    ---
    name: git-release
    description: Create consistent releases and changelogs
    ---

    ## What I do

    - Draft release notes from merged PRs
    - Propose a version bump
    - Provide a copy-pasteable `gh release create` command
  '';

  # A skill can also be a directory containing SKILL.md and other files.
  data-analysis = ./skills/data-analysis;

  # A skill can also be a subdirectory within a package source (store path)
  beads = "${pkgs.beads.src}/claude-plugin/skills/beads";
}
Declared
<home-manager/modules/programs/opencode.nix>