Skip to content
Merged
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
6 changes: 6 additions & 0 deletions pkg/client/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -268,6 +268,9 @@ var supportedClientIntegrations = []clientAppConfig{
types.TransportTypeSSE: "url",
types.TransportTypeStreamableHTTP: "url",
},
SupportsSkills: true,
SkillsGlobalPath: []string{".copilot", "skills"},
SkillsProjectPath: []string{".github", "skills"},
},
{
ClientType: VSCode,
Expand All @@ -294,6 +297,9 @@ var supportedClientIntegrations = []clientAppConfig{
types.TransportTypeSSE: "url",
types.TransportTypeStreamableHTTP: "url",
},
SupportsSkills: true,
SkillsGlobalPath: []string{".copilot", "skills"},
SkillsProjectPath: []string{".github", "skills"},
},
{
ClientType: Cursor,
Comment thread
samuv marked this conversation as resolved.
Expand Down
15 changes: 9 additions & 6 deletions pkg/client/discovery_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -121,11 +121,14 @@ func TestGetClientStatus(t *testing.T) {
SkillsProjectPath: []string{".cursor", "skills"},
},
{
ClientType: VSCode,
Description: "Visual Studio Code (Test)",
SettingsFile: "mcp.json",
RelPath: []string{".config", "Code", "User"}, // This path won't exist in test
Extension: JSON,
ClientType: VSCode,
Description: "Visual Studio Code (Test)",
SettingsFile: "mcp.json",
RelPath: []string{".config", "Code", "User"}, // This path won't exist in test
Extension: JSON,
SupportsSkills: true,
SkillsGlobalPath: []string{".copilot", "skills"},
SkillsProjectPath: []string{".github", "skills"},
},
}

Expand Down Expand Up @@ -157,7 +160,7 @@ func TestGetClientStatus(t *testing.T) {
assert.True(t, exists)
assert.False(t, vscodeStatus.Installed)
assert.False(t, vscodeStatus.Registered)
assert.False(t, vscodeStatus.SupportsSkills)
assert.True(t, vscodeStatus.SupportsSkills)
}

func TestGetClientStatus_Sorting(t *testing.T) {
Expand Down
53 changes: 49 additions & 4 deletions pkg/client/skills_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,19 @@ func testSkillClientIntegrations() []clientAppConfig {
SkillsProjectPath: []string{".kimi", "skills"},
},
{
ClientType: VSCode,
ClientType: VSCode,
SupportsSkills: true,
SkillsGlobalPath: []string{".copilot", "skills"},
SkillsProjectPath: []string{".github", "skills"},
},
{
ClientType: VSCodeInsider,
SupportsSkills: true,
SkillsGlobalPath: []string{".copilot", "skills"},
SkillsProjectPath: []string{".github", "skills"},
},
{
ClientType: Windsurf,
// SupportsSkills defaults to false
},
{
Expand Down Expand Up @@ -84,6 +96,9 @@ func TestSupportsSkills(t *testing.T) {
{name: "OpenCode supports skills", client: OpenCode, expected: true},
{name: "Cursor supports skills", client: Cursor, expected: true},
{name: "KimiCli supports skills", client: KimiCli, expected: true},
{name: "VSCode supports skills", client: VSCode, expected: true},
{name: "VSCodeInsider supports skills", client: VSCodeInsider, expected: true},
{name: "Windsurf does not support skills", client: Windsurf, expected: false},
{name: "unknown client returns false", client: ClientApp("nonexistent"), expected: false},
}

Expand All @@ -100,8 +115,8 @@ func TestListSkillSupportingClients(t *testing.T) {
cm := newTestSkillManager()
clients := cm.ListSkillSupportingClients()

// Should include ClaudeCode, Codex, Cursor, KimiCli, OpenCode, and our test-only no-paths-client
require.Len(t, clients, 6, "unexpected number of skill-supporting clients: %v", clients)
// Should include ClaudeCode, Codex, Cursor, KimiCli, OpenCode, VSCode, VSCodeInsider, and our test-only no-paths-client
require.Len(t, clients, 8, "unexpected number of skill-supporting clients: %v", clients)

// Verify sorted order
for i := 1; i < len(clients); i++ {
Expand Down Expand Up @@ -229,10 +244,40 @@ func TestGetSkillPath(t *testing.T) {
wantPath: filepath.Join("/tmp/myproject", ".kimi", "skills", "my-skill"),
},
{
name: "client that does not support skills",
name: "ScopeUser VSCode",
client: VSCode,
skillName: "my-skill",
scope: skills.ScopeUser,
wantPath: filepath.Join(testHomeDir, ".copilot", "skills", "my-skill"),
},
{
name: "ScopeProject VSCode with explicit root",
client: VSCode,
skillName: "my-skill",
scope: skills.ScopeProject,
projectRoot: "/tmp/myproject",
wantPath: filepath.Join("/tmp/myproject", ".github", "skills", "my-skill"),
},
{
name: "ScopeUser VSCodeInsider",
client: VSCodeInsider,
skillName: "my-skill",
scope: skills.ScopeUser,
wantPath: filepath.Join(testHomeDir, ".copilot", "skills", "my-skill"),
},
{
name: "ScopeProject VSCodeInsider with explicit root",
client: VSCodeInsider,
skillName: "my-skill",
scope: skills.ScopeProject,
projectRoot: "/tmp/myproject",
wantPath: filepath.Join("/tmp/myproject", ".github", "skills", "my-skill"),
},
{
name: "client that does not support skills",
client: Windsurf,
skillName: "my-skill",
scope: skills.ScopeUser,
wantErr: ErrSkillsNotSupported,
},
{
Expand Down
Loading