From 576f3266a99cedfbdc57e65ca0ef435ca87fdd03 Mon Sep 17 00:00:00 2001 From: LuluBeatson Date: Tue, 8 Jul 2025 11:53:43 +0100 Subject: [PATCH 1/3] sha arg prompt as required if updating file --- pkg/github/repositories.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/github/repositories.go b/pkg/github/repositories.go index cf71a5839..8cd4fc29d 100644 --- a/pkg/github/repositories.go +++ b/pkg/github/repositories.go @@ -288,7 +288,7 @@ func CreateOrUpdateFile(getClient GetClientFn, t translations.TranslationHelperF mcp.Description("Branch to create/update the file in"), ), mcp.WithString("sha", - mcp.Description("SHA of file being replaced (for updates)"), + mcp.Description("Required if you are updating an existing file. The blob SHA of the file being replaced."), ), ), func(ctx context.Context, request mcp.CallToolRequest) (*mcp.CallToolResult, error) { From 67b39387b3ec245e77510e9d8861fba7744e76eb Mon Sep 17 00:00:00 2001 From: LuluBeatson Date: Tue, 8 Jul 2025 12:00:26 +0100 Subject: [PATCH 2/3] generate docs and toolsnaps --- README.md | 2 +- pkg/github/__toolsnaps__/create_or_update_file.snap | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 8ba842a46..51a53c43d 100644 --- a/README.md +++ b/README.md @@ -870,7 +870,7 @@ export GITHUB_MCP_TOOL_ADD_ISSUE_COMMENT_DESCRIPTION="an alternative description - `owner`: Repository owner (username or organization) (string, required) - `path`: Path where to create/update the file (string, required) - `repo`: Repository name (string, required) - - `sha`: SHA of file being replaced (for updates) (string, optional) + - `sha`: Required if you are updating an existing file. The blob SHA of the file being replaced. (string, optional) - **create_repository** - Create repository - `autoInit`: Initialize with README (boolean, optional) diff --git a/pkg/github/__toolsnaps__/create_or_update_file.snap b/pkg/github/__toolsnaps__/create_or_update_file.snap index dfbb34423..dd76cfa44 100644 --- a/pkg/github/__toolsnaps__/create_or_update_file.snap +++ b/pkg/github/__toolsnaps__/create_or_update_file.snap @@ -31,7 +31,7 @@ "type": "string" }, "sha": { - "description": "SHA of file being replaced (for updates)", + "description": "Required if you are updating an existing file. The blob SHA of the file being replaced.", "type": "string" } }, From 3363d447472d8cca02462404b16720f198dbdab2 Mon Sep 17 00:00:00 2001 From: LuluBeatson Date: Tue, 8 Jul 2025 12:04:25 +0100 Subject: [PATCH 3/3] shorten --- README.md | 2 +- pkg/github/__toolsnaps__/create_or_update_file.snap | 2 +- pkg/github/repositories.go | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 51a53c43d..70e8c3ca1 100644 --- a/README.md +++ b/README.md @@ -870,7 +870,7 @@ export GITHUB_MCP_TOOL_ADD_ISSUE_COMMENT_DESCRIPTION="an alternative description - `owner`: Repository owner (username or organization) (string, required) - `path`: Path where to create/update the file (string, required) - `repo`: Repository name (string, required) - - `sha`: Required if you are updating an existing file. The blob SHA of the file being replaced. (string, optional) + - `sha`: Required if updating an existing file. The blob SHA of the file being replaced. (string, optional) - **create_repository** - Create repository - `autoInit`: Initialize with README (boolean, optional) diff --git a/pkg/github/__toolsnaps__/create_or_update_file.snap b/pkg/github/__toolsnaps__/create_or_update_file.snap index dd76cfa44..61adef72c 100644 --- a/pkg/github/__toolsnaps__/create_or_update_file.snap +++ b/pkg/github/__toolsnaps__/create_or_update_file.snap @@ -31,7 +31,7 @@ "type": "string" }, "sha": { - "description": "Required if you are updating an existing file. The blob SHA of the file being replaced.", + "description": "Required if updating an existing file. The blob SHA of the file being replaced.", "type": "string" } }, diff --git a/pkg/github/repositories.go b/pkg/github/repositories.go index 8cd4fc29d..8a7a8af4a 100644 --- a/pkg/github/repositories.go +++ b/pkg/github/repositories.go @@ -288,7 +288,7 @@ func CreateOrUpdateFile(getClient GetClientFn, t translations.TranslationHelperF mcp.Description("Branch to create/update the file in"), ), mcp.WithString("sha", - mcp.Description("Required if you are updating an existing file. The blob SHA of the file being replaced."), + mcp.Description("Required if updating an existing file. The blob SHA of the file being replaced."), ), ), func(ctx context.Context, request mcp.CallToolRequest) (*mcp.CallToolResult, error) { pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy