Add --category option to cmdforge create command
Tools support categories (Text, Developer, Data, Other) but the CLI create command was missing this option. Now users can specify a category when creating tools from the command line. Co-Authored-By: Claude Opus 4.5 <[email protected]>
This commit is contained in:
@@ -35,6 +35,7 @@ def main():
|
||||
p_create = subparsers.add_parser("create", help="Create a new tool")
|
||||
p_create.add_argument("name", help="Tool name")
|
||||
p_create.add_argument("-d", "--description", help="Tool description")
|
||||
p_create.add_argument("-c", "--category", choices=["Text", "Developer", "Data", "Other"], default="Other", help="Tool category")
|
||||
p_create.add_argument("-p", "--prompt", help="Prompt template")
|
||||
p_create.add_argument("--provider", help="AI provider (default: mock)")
|
||||
p_create.add_argument("-f", "--force", action="store_true", help="Overwrite existing")
|
||||
|
||||
@@ -77,6 +77,7 @@ def cmd_create(args):
|
||||
tool = Tool(
|
||||
name=name,
|
||||
description=args.description or "",
|
||||
category=args.category or "Other",
|
||||
arguments=[],
|
||||
steps=steps,
|
||||
output="{response}" if steps else "{input}"
|
||||
|
||||
Reference in New Issue
Block a user