Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions internal/store/pg/skills_content.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,11 @@ func (s *PGSkillStore) LoadSkill(ctx context.Context, name string) (string, bool
if err != nil {
return "", false
}
// Resolve {baseDir} placeholder so SKILL.md script-invocation lines hold
// absolute paths regardless of agent CWD. Mirrors skills.Loader.LoadSkill
// substitution; without it, agents reading SKILL.md via this RPC see the
// literal placeholder.
content = strings.ReplaceAll(content, "{baseDir}", info.BaseDir)
return content, true
}

Expand Down
5 changes: 5 additions & 0 deletions internal/store/sqlitestore/skills_content.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,11 @@ func (s *SQLiteSkillStore) LoadSkill(ctx context.Context, name string) (string,
if err != nil {
return "", false
}
// Resolve {baseDir} placeholder so SKILL.md script-invocation lines hold
// absolute paths regardless of agent CWD. Mirrors skills.Loader.LoadSkill
// substitution; without it, agents reading SKILL.md via this RPC see the
// literal placeholder.
content = strings.ReplaceAll(content, "{baseDir}", info.BaseDir)
return content, true
}

Expand Down
Loading