Skip to content

feat: add support for reading skills from .agents/skills directories#11842

Merged
thdxr merged 2 commits intodevfrom
opencode/crisp-orchid
Feb 3, 2026
Merged

feat: add support for reading skills from .agents/skills directories#11842
thdxr merged 2 commits intodevfrom
opencode/crisp-orchid

Conversation

@thdxr
Copy link
Contributor

@thdxr thdxr commented Feb 2, 2026

Summary

This PR adds support for reading skills from .agents/skills/ directories, similar to how .claude/skills/ is already supported.

Changes

  • Added scanning for project-level .agents/skills/ directories (searches up the directory tree from the current working directory)
  • Added support for global ~/.agents/skills/ directory
  • Uses the same CLAUDE_SKILL_GLOB pattern (skills/**/SKILL.md) to find skill files
  • Follows the same error handling and logging patterns as the existing .claude/skills implementation

Use Case

Users who organize their AI assistant configurations in .agents/ directories (instead of or in addition to .claude/) can now have their skills automatically loaded by opencode.

Testing

The implementation follows the same patterns as the existing .claude/skills scanning:

  • Uses Filesystem.up() to find .agents directories in parent folders
  • Checks for global ~/.agents directory
  • Uses existing addSkill() function to parse and register skills

@thdxr thdxr force-pushed the opencode/crisp-orchid branch 8 times, most recently from 3b2988a to b14e7f5 Compare February 2, 2026 21:09
@thdxr thdxr enabled auto-merge (squash) February 2, 2026 21:11
@thdxr thdxr force-pushed the opencode/crisp-orchid branch from b14e7f5 to e687553 Compare February 2, 2026 21:13
@antonio-ivanovski
Copy link

Will this be applicable for both project and global skills?

@thdxr thdxr force-pushed the opencode/crisp-orchid branch 3 times, most recently from a3157fd to c3e711d Compare February 2, 2026 21:17
@thdxr thdxr disabled auto-merge February 2, 2026 21:19
@thdxr thdxr force-pushed the opencode/crisp-orchid branch 2 times, most recently from 2206186 to 1d8a993 Compare February 2, 2026 21:19
@thdxr thdxr enabled auto-merge (squash) February 2, 2026 21:19
@ben-vargas
Copy link
Contributor

ben-vargas commented Feb 2, 2026

Just make sure you guys are on the same page... PR says .agent/skills and Alexander's x post says .agents/skills 😅
CleanShot 2026-02-02 at 14 27 40@2x

Edit: external pattern in skill.ts looks good though, just a PR doc issue.

@gverma-openai
Copy link

gverma-openai commented Feb 2, 2026

Just make sure you guys are on the same page... PR says .agent/skills and Alexander's x post says .agents/skills 😅

Correct, the recommendation is to use .agents/skills (plural).

@thdxr thdxr changed the title feat: add support for reading skills from .agent/skills directories feat: add support for reading skills from .agents/skills directories Feb 2, 2026
@thdxr thdxr added the beta label Feb 2, 2026
@thdxr thdxr disabled auto-merge February 3, 2026 04:08
opencode-agent bot added a commit that referenced this pull request Feb 3, 2026
opencode-agent bot added a commit that referenced this pull request Feb 3, 2026
opencode-agent bot added a commit that referenced this pull request Feb 3, 2026
opencode-agent bot added a commit that referenced this pull request Feb 3, 2026
opencode-agent bot added a commit that referenced this pull request Feb 3, 2026
@adamdotdevin adamdotdevin force-pushed the opencode/crisp-orchid branch 2 times, most recently from 5b6cf03 to 5a8ee88 Compare February 3, 2026 12:17
opencode-agent bot added a commit that referenced this pull request Feb 3, 2026
opencode-agent bot added a commit that referenced this pull request Feb 3, 2026
opencode-agent bot added a commit that referenced this pull request Feb 3, 2026
opencode-agent bot added a commit that referenced this pull request Feb 3, 2026
opencode-agent bot added a commit that referenced this pull request Feb 3, 2026
opencode-agent bot added a commit that referenced this pull request Feb 3, 2026
opencode-agent bot added a commit that referenced this pull request Feb 3, 2026
opencode-agent bot added a commit that referenced this pull request Feb 3, 2026
@thdxr thdxr merged commit 17e62b0 into dev Feb 3, 2026
4 checks passed
@thdxr thdxr deleted the opencode/crisp-orchid branch February 3, 2026 20:51
mvclaudianobj pushed a commit to mvclaudianobj/markscode that referenced this pull request Feb 4, 2026
…nomalyco#11842)

Co-authored-by: Filip <34747899+neriousy@users.noreply.github.com>
ishaksebsib pushed a commit to ishaksebsib/opencode that referenced this pull request Feb 4, 2026
…nomalyco#11842)

Co-authored-by: Filip <34747899+neriousy@users.noreply.github.com>
ishaksebsib pushed a commit to ishaksebsib/opencode that referenced this pull request Feb 4, 2026
…nomalyco#11842)

Co-authored-by: Filip <34747899+neriousy@users.noreply.github.com>
dmae97 pushed a commit to dmae97/opencode that referenced this pull request Feb 5, 2026
…nomalyco#11842)

Co-authored-by: Filip <34747899+neriousy@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants