diff --git a/integrations/catalog.json b/integrations/catalog.json index 601ae0ad92..221ba15d9d 100644 --- a/integrations/catalog.json +++ b/integrations/catalog.json @@ -177,8 +177,8 @@ "bob": { "id": "bob", "name": "IBM Bob", - "version": "1.0.0", - "description": "IBM Bob IDE integration", + "version": "2.0.0", + "description": "IBM Bob 2.0 IDE integration", "author": "spec-kit-core", "repository": "https://github.com/github/spec-kit", "tags": ["ide", "ibm"] diff --git a/src/specify_cli/integrations/bob/__init__.py b/src/specify_cli/integrations/bob/__init__.py index b953151bd2..d4c75ef425 100644 --- a/src/specify_cli/integrations/bob/__init__.py +++ b/src/specify_cli/integrations/bob/__init__.py @@ -1,20 +1,39 @@ -"""IBM Bob integration.""" +"""IBM Bob integration. -from ..base import MarkdownIntegration +Bob 2.0 uses the ``.bob/skills/speckit-/SKILL.md`` layout. +The legacy ``.bob/commands/`` layout (Bob 1.x) is no longer supported. +""" +from __future__ import annotations + +from ..base import IntegrationOption, SkillsIntegration + + +class BobIntegration(SkillsIntegration): + """Integration for IBM Bob IDE.""" -class BobIntegration(MarkdownIntegration): key = "bob" config = { "name": "IBM Bob", "folder": ".bob/", - "commands_subdir": "commands", + "commands_subdir": "skills", "install_url": None, "requires_cli": False, } registrar_config = { - "dir": ".bob/commands", + "dir": ".bob/skills", "format": "markdown", "args": "$ARGUMENTS", - "extension": ".md", + "extension": "/SKILL.md", } + + @classmethod + def options(cls) -> list[IntegrationOption]: + return [ + IntegrationOption( + "--skills", + is_flag=True, + default=True, + help="Install as agent skills (default for Bob 2.0)", + ), + ] diff --git a/tests/integrations/test_integration_bob.py b/tests/integrations/test_integration_bob.py index 8e0e72f0bd..a5cf8f70d4 100644 --- a/tests/integrations/test_integration_bob.py +++ b/tests/integrations/test_integration_bob.py @@ -1,10 +1,10 @@ """Tests for BobIntegration.""" -from .test_integration_base_markdown import MarkdownIntegrationTests +from .test_integration_base_skills import SkillsIntegrationTests -class TestBobIntegration(MarkdownIntegrationTests): +class TestBobIntegration(SkillsIntegrationTests): KEY = "bob" FOLDER = ".bob/" - COMMANDS_SUBDIR = "commands" - REGISTRAR_DIR = ".bob/commands" + COMMANDS_SUBDIR = "skills" + REGISTRAR_DIR = ".bob/skills"