From 8fd0328109ec6e15357e59c9dd07f1db4f26b33e Mon Sep 17 00:00:00 2001 From: ssalbdivad Date: Thu, 9 Oct 2025 17:26:01 -0400 Subject: [PATCH] propagate GITHUB_REPOSITORY --- entry.cjs | 7 ++++++- mcp/config.ts | 6 ++++++ package.json | 2 +- 3 files changed, 13 insertions(+), 2 deletions(-) diff --git a/entry.cjs b/entry.cjs index 0085762..f236eea 100755 --- a/entry.cjs +++ b/entry.cjs @@ -25506,6 +25506,10 @@ var core = __toESM(require_core(), 1); // mcp/config.ts var actionPath = process.env.GITHUB_ACTION_PATH || process.cwd(); function createMcpConfig(githubInstallationToken) { + const githubRepository = process.env.GITHUB_REPOSITORY; + if (!githubRepository) { + throw new Error("GITHUB_REPOSITORY environment variable is required for MCP GitHub integration"); + } return JSON.stringify( { mcpServers: { @@ -25513,7 +25517,8 @@ function createMcpConfig(githubInstallationToken) { command: "node", args: [`${actionPath}/mcp/server.ts`], env: { - GITHUB_INSTALLATION_TOKEN: githubInstallationToken + GITHUB_INSTALLATION_TOKEN: githubInstallationToken, + GITHUB_REPOSITORY: githubRepository } } } diff --git a/mcp/config.ts b/mcp/config.ts index 5ab238d..6d64471 100644 --- a/mcp/config.ts +++ b/mcp/config.ts @@ -4,6 +4,11 @@ const actionPath = process.env.GITHUB_ACTION_PATH || process.cwd(); export function createMcpConfig(githubInstallationToken: string) { + const githubRepository = process.env.GITHUB_REPOSITORY; + if (!githubRepository) { + throw new Error('GITHUB_REPOSITORY environment variable is required for MCP GitHub integration'); + } + return JSON.stringify( { mcpServers: { @@ -12,6 +17,7 @@ export function createMcpConfig(githubInstallationToken: string) { args: [`${actionPath}/mcp/server.ts`], env: { GITHUB_INSTALLATION_TOKEN: githubInstallationToken, + GITHUB_REPOSITORY: githubRepository, }, }, }, diff --git a/package.json b/package.json index 1c20a97..50892b9 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@pullfrog/action", - "version": "0.0.15", + "version": "0.0.16", "type": "module", "files": [ "index.js",