From ea3e5c2ca557d04563fd203adb16d4d288d9d208 Mon Sep 17 00:00:00 2001 From: Ammar Bandukwala Date: Sat, 4 Oct 2025 15:33:17 -0500 Subject: [PATCH 1/2] Fix CI double-run on pull requests When a branch has an open PR, pushing to it triggers both the 'push' and 'pull_request' events, causing CI to run twice. This change limits 'push' triggers to only the main branch, while keeping 'pull_request' triggers for all branches. This is the standard GitHub Actions pattern to prevent duplicate runs. --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 699cdc693e..c30478ab5a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -2,7 +2,7 @@ name: CI on: push: - branches: ["**"] + branches: ["main"] pull_request: branches: ["**"] From 4718e4f35612b38a305726d2240abd76692c0f39 Mon Sep 17 00:00:00 2001 From: Ammar Bandukwala Date: Sat, 4 Oct 2025 15:37:28 -0500 Subject: [PATCH 2/2] Optimize bash tool description to prevent redundant cd commands The bash tool already runs commands in the configured cwd, but the previous description 'cwd: /path' was ambiguous and didn't explicitly prevent the redundant pattern of starting every command with 'cd /path &&'. Updated to 'Runs in /path - no cd needed' which: - Clearly states commands already run in that directory - Explicitly prevents the anti-pattern - Uses fewer tokens (~same length but clearer) --- src/services/tools/bash.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/services/tools/bash.ts b/src/services/tools/bash.ts index 872515802b..dea94cdba4 100644 --- a/src/services/tools/bash.ts +++ b/src/services/tools/bash.ts @@ -30,7 +30,7 @@ class DisposableProcess implements Disposable { */ export const createBashTool: ToolFactory = (config: ToolConfiguration) => { return tool({ - description: TOOL_DEFINITIONS.bash.description + "\ncwd: " + config.cwd, + description: TOOL_DEFINITIONS.bash.description + "\nRuns in " + config.cwd + " - no cd needed", inputSchema: TOOL_DEFINITIONS.bash.schema, execute: async ({ script, timeout_secs, max_lines }): Promise => { const startTime = performance.now();