Skip to content

Commit 711d853

Browse files
authored
use description field (#8)
1 parent e8933f0 commit 711d853

1 file changed

Lines changed: 8 additions & 10 deletions

File tree

main.py

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -51,12 +51,7 @@ async def run_command(cmd: list[str], timeout: float = 30.0) -> str:
5151

5252

5353
@mcp.tool(
54-
description="Get Conan profile configuration for the user's platform and build environment"
55-
)
56-
async def get_conan_profile(
57-
profile: str = Field(default=None, description="Specific profile name to retrieve. If not provided, uses the default profile.")
58-
) -> dict:
59-
"""Get Conan profile configuration.
54+
description="""Get Conan profile configuration.
6055
6156
This tool should be called when the user mentions:
6257
- Their platform (Windows, macOS, Linux)
@@ -81,6 +76,10 @@ async def get_conan_profile(
8176
- "build": Build profile settings (compiler, arch, build_type, etc.)
8277
- Additional configuration like package_settings, options, tool_requires, etc.
8378
"""
79+
)
80+
async def get_conan_profile(
81+
profile: str = Field(default=None, description="Specific profile name to retrieve. If not provided, uses the default profile.")
82+
) -> dict:
8483
cmd = ["conan", "profile", "show", "--format=json"]
8584
if profile:
8685
cmd.extend(["--profile", profile])
@@ -89,16 +88,15 @@ async def get_conan_profile(
8988

9089

9190
@mcp.tool(
92-
description="List available Conan profiles."
93-
)
94-
async def list_conan_profiles() -> list[str]:
95-
"""List Conan profiles available.
91+
description="""List Conan profiles available.
9692
9793
Use this tool to see which profiles are available to select or inspect.
9894
9995
Returns:
10096
List of profile names.
10197
"""
98+
)
99+
async def list_conan_profiles() -> list[str]:
102100
cmd = ["conan", "profile", "list", "--format=json"]
103101
raw_output = await run_command(cmd)
104102
return json.loads(raw_output)

0 commit comments

Comments
 (0)