Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitf7e1320

Browse files
committed
feat: enhance GitHub Actions tools with user-friendly titles
- Added user-friendly titles to tool annotations for various GitHub Actions tools, improving clarity and usability for end-users.- Updated descriptions for tools including ListWorkflows, ListWorkflowRuns, RunWorkflow, and others to include new titles for better identification and understanding of their functionalities.
1 parentd8285fe commitf7e1320

File tree

1 file changed

+16
-1
lines changed

1 file changed

+16
-1
lines changed

‎pkg/github/actions.go

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ func ListWorkflows(getClient GetClientFn, t translations.TranslationHelperFunc)
2424
returnmcp.NewTool("list_workflows",
2525
mcp.WithDescription(t("TOOL_LIST_WORKFLOWS_DESCRIPTION","List workflows in a repository")),
2626
mcp.WithToolAnnotation(mcp.ToolAnnotation{
27+
Title:t("TOOL_LIST_WORKFLOWS_USER_TITLE","List workflows"),
2728
ReadOnlyHint:ToBoolPtr(true),
2829
}),
2930
mcp.WithString("owner",
@@ -92,6 +93,7 @@ func ListWorkflowRuns(getClient GetClientFn, t translations.TranslationHelperFun
9293
returnmcp.NewTool("list_workflow_runs",
9394
mcp.WithDescription(t("TOOL_LIST_WORKFLOW_RUNS_DESCRIPTION","List workflow runs for a specific workflow")),
9495
mcp.WithToolAnnotation(mcp.ToolAnnotation{
96+
Title:t("TOOL_LIST_WORKFLOW_RUNS_USER_TITLE","List workflow runs"),
9597
ReadOnlyHint:ToBoolPtr(true),
9698
}),
9799
mcp.WithString("owner",
@@ -239,6 +241,7 @@ func RunWorkflow(getClient GetClientFn, t translations.TranslationHelperFunc) (t
239241
returnmcp.NewTool("run_workflow",
240242
mcp.WithDescription(t("TOOL_RUN_WORKFLOW_DESCRIPTION","Run an Actions workflow by workflow ID")),
241243
mcp.WithToolAnnotation(mcp.ToolAnnotation{
244+
Title:t("TOOL_RUN_WORKFLOW_USER_TITLE","Run workflow"),
242245
ReadOnlyHint:ToBoolPtr(false),
243246
}),
244247
mcp.WithString("owner",
@@ -329,6 +332,7 @@ func RunWorkflowByFileName(getClient GetClientFn, t translations.TranslationHelp
329332
returnmcp.NewTool("run_workflow_by_filename",
330333
mcp.WithDescription(t("TOOL_RUN_WORKFLOW_BY_FILENAME_DESCRIPTION","Run an Actions workflow by workflow filename")),
331334
mcp.WithToolAnnotation(mcp.ToolAnnotation{
335+
Title:t("TOOL_RUN_WORKFLOW_BY_FILENAME_USER_TITLE","Run workflow by filename"),
332336
ReadOnlyHint:ToBoolPtr(false),
333337
}),
334338
mcp.WithString("owner",
@@ -416,6 +420,7 @@ func GetWorkflowRun(getClient GetClientFn, t translations.TranslationHelperFunc)
416420
returnmcp.NewTool("get_workflow_run",
417421
mcp.WithDescription(t("TOOL_GET_WORKFLOW_RUN_DESCRIPTION","Get details of a specific workflow run")),
418422
mcp.WithToolAnnotation(mcp.ToolAnnotation{
423+
Title:t("TOOL_GET_WORKFLOW_RUN_USER_TITLE","Get workflow run"),
419424
ReadOnlyHint:ToBoolPtr(true),
420425
}),
421426
mcp.WithString("owner",
@@ -471,6 +476,7 @@ func GetWorkflowRunLogs(getClient GetClientFn, t translations.TranslationHelperF
471476
returnmcp.NewTool("get_workflow_run_logs",
472477
mcp.WithDescription(t("TOOL_GET_WORKFLOW_RUN_LOGS_DESCRIPTION","Download logs for a specific workflow run (EXPENSIVE: downloads ALL logs as ZIP. Consider using get_job_logs with failed_only=true for debugging failed jobs)")),
473478
mcp.WithToolAnnotation(mcp.ToolAnnotation{
479+
Title:t("TOOL_GET_WORKFLOW_RUN_LOGS_USER_TITLE","Get workflow run logs"),
474480
ReadOnlyHint:ToBoolPtr(true),
475481
}),
476482
mcp.WithString("owner",
@@ -536,6 +542,7 @@ func ListWorkflowJobs(getClient GetClientFn, t translations.TranslationHelperFun
536542
returnmcp.NewTool("list_workflow_jobs",
537543
mcp.WithDescription(t("TOOL_LIST_WORKFLOW_JOBS_DESCRIPTION","List jobs for a specific workflow run")),
538544
mcp.WithToolAnnotation(mcp.ToolAnnotation{
545+
Title:t("TOOL_LIST_WORKFLOW_JOBS_USER_TITLE","List workflow jobs"),
539546
ReadOnlyHint:ToBoolPtr(true),
540547
}),
541548
mcp.WithString("owner",
@@ -627,11 +634,12 @@ func ListWorkflowJobs(getClient GetClientFn, t translations.TranslationHelperFun
627634
}
628635
}
629636

630-
// GetJobLogs creates a tool to download logs for a specific workflow job or get failed job logsefficiently
637+
// GetJobLogs creates a tool to download logs for a specific workflow job orefficientlygetallfailed job logsfor a workflow run
631638
funcGetJobLogs(getClientGetClientFn,t translations.TranslationHelperFunc) (tool mcp.Tool,handler server.ToolHandlerFunc) {
632639
returnmcp.NewTool("get_job_logs",
633640
mcp.WithDescription(t("TOOL_GET_JOB_LOGS_DESCRIPTION","Download logs for a specific workflow job or efficiently get all failed job logs for a workflow run")),
634641
mcp.WithToolAnnotation(mcp.ToolAnnotation{
642+
Title:t("TOOL_GET_JOB_LOGS_USER_TITLE","Get job logs"),
635643
ReadOnlyHint:ToBoolPtr(true),
636644
}),
637645
mcp.WithString("owner",
@@ -846,6 +854,7 @@ func RerunWorkflowRun(getClient GetClientFn, t translations.TranslationHelperFun
846854
returnmcp.NewTool("rerun_workflow_run",
847855
mcp.WithDescription(t("TOOL_RERUN_WORKFLOW_RUN_DESCRIPTION","Re-run an entire workflow run")),
848856
mcp.WithToolAnnotation(mcp.ToolAnnotation{
857+
Title:t("TOOL_RERUN_WORKFLOW_RUN_USER_TITLE","Rerun workflow run"),
849858
ReadOnlyHint:ToBoolPtr(false),
850859
}),
851860
mcp.WithString("owner",
@@ -908,6 +917,7 @@ func RerunFailedJobs(getClient GetClientFn, t translations.TranslationHelperFunc
908917
returnmcp.NewTool("rerun_failed_jobs",
909918
mcp.WithDescription(t("TOOL_RERUN_FAILED_JOBS_DESCRIPTION","Re-run only the failed jobs in a workflow run")),
910919
mcp.WithToolAnnotation(mcp.ToolAnnotation{
920+
Title:t("TOOL_RERUN_FAILED_JOBS_USER_TITLE","Rerun failed jobs"),
911921
ReadOnlyHint:ToBoolPtr(false),
912922
}),
913923
mcp.WithString("owner",
@@ -970,6 +980,7 @@ func CancelWorkflowRun(getClient GetClientFn, t translations.TranslationHelperFu
970980
returnmcp.NewTool("cancel_workflow_run",
971981
mcp.WithDescription(t("TOOL_CANCEL_WORKFLOW_RUN_DESCRIPTION","Cancel a workflow run")),
972982
mcp.WithToolAnnotation(mcp.ToolAnnotation{
983+
Title:t("TOOL_CANCEL_WORKFLOW_RUN_USER_TITLE","Cancel workflow run"),
973984
ReadOnlyHint:ToBoolPtr(false),
974985
}),
975986
mcp.WithString("owner",
@@ -1032,6 +1043,7 @@ func ListWorkflowRunArtifacts(getClient GetClientFn, t translations.TranslationH
10321043
returnmcp.NewTool("list_workflow_run_artifacts",
10331044
mcp.WithDescription(t("TOOL_LIST_WORKFLOW_RUN_ARTIFACTS_DESCRIPTION","List artifacts for a workflow run")),
10341045
mcp.WithToolAnnotation(mcp.ToolAnnotation{
1046+
Title:t("TOOL_LIST_WORKFLOW_RUN_ARTIFACTS_USER_TITLE","List workflow artifacts"),
10351047
ReadOnlyHint:ToBoolPtr(true),
10361048
}),
10371049
mcp.WithString("owner",
@@ -1109,6 +1121,7 @@ func DownloadWorkflowRunArtifact(getClient GetClientFn, t translations.Translati
11091121
returnmcp.NewTool("download_workflow_run_artifact",
11101122
mcp.WithDescription(t("TOOL_DOWNLOAD_WORKFLOW_RUN_ARTIFACT_DESCRIPTION","Get download URL for a workflow run artifact")),
11111123
mcp.WithToolAnnotation(mcp.ToolAnnotation{
1124+
Title:t("TOOL_DOWNLOAD_WORKFLOW_RUN_ARTIFACT_USER_TITLE","Download workflow artifact"),
11121125
ReadOnlyHint:ToBoolPtr(true),
11131126
}),
11141127
mcp.WithString("owner",
@@ -1173,6 +1186,7 @@ func DeleteWorkflowRunLogs(getClient GetClientFn, t translations.TranslationHelp
11731186
returnmcp.NewTool("delete_workflow_run_logs",
11741187
mcp.WithDescription(t("TOOL_DELETE_WORKFLOW_RUN_LOGS_DESCRIPTION","Delete logs for a workflow run")),
11751188
mcp.WithToolAnnotation(mcp.ToolAnnotation{
1189+
Title:t("TOOL_DELETE_WORKFLOW_RUN_LOGS_USER_TITLE","Delete workflow logs"),
11761190
ReadOnlyHint:ToBoolPtr(false),
11771191
DestructiveHint:ToBoolPtr(true),
11781192
}),
@@ -1236,6 +1250,7 @@ func GetWorkflowRunUsage(getClient GetClientFn, t translations.TranslationHelper
12361250
returnmcp.NewTool("get_workflow_run_usage",
12371251
mcp.WithDescription(t("TOOL_GET_WORKFLOW_RUN_USAGE_DESCRIPTION","Get usage metrics for a workflow run")),
12381252
mcp.WithToolAnnotation(mcp.ToolAnnotation{
1253+
Title:t("TOOL_GET_WORKFLOW_RUN_USAGE_USER_TITLE","Get workflow usage"),
12391254
ReadOnlyHint:ToBoolPtr(true),
12401255
}),
12411256
mcp.WithString("owner",

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp