From dcd2d50768363e61fdf556e81abada8aa54996de Mon Sep 17 00:00:00 2001 From: Julius Marminge Date: Mon, 2 Mar 2026 20:08:27 -0800 Subject: [PATCH] Keep non-default quick action on full PR flow Co-authored-by: codex --- apps/web/src/components/GitActionsControl.logic.test.ts | 6 +++--- apps/web/src/components/GitActionsControl.logic.ts | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/apps/web/src/components/GitActionsControl.logic.test.ts b/apps/web/src/components/GitActionsControl.logic.test.ts index 720f32af631e784f826b36d05b304c657a615dba..8bf548515192e26cbaed1988d3e8ded3f1f3168a 100644 --- a/apps/web/src/components/GitActionsControl.logic.test.ts +++ b/apps/web/src/components/GitActionsControl.logic.test.ts @@ -365,7 +365,7 @@ describe("when: working tree has local changes", () => { }); }); - it("resolveQuickAction returns commit and push when open PR exists", () => { + it("resolveQuickAction keeps full commit/push/pr flow on non-default branches even when PR exists", () => { const quick = resolveQuickAction( status({ hasWorkingTreeChanges: true, @@ -382,8 +382,8 @@ describe("when: working tree has local changes", () => { ); assert.deepInclude(quick, { kind: "run_action", - action: "commit_push", - label: "Commit & push", + action: "commit_push_pr", + label: "Commit, push & create PR", }); }); diff --git a/apps/web/src/components/GitActionsControl.logic.ts b/apps/web/src/components/GitActionsControl.logic.ts index ccb78be31862bc56c7fe15b970f208c76227097f..59cb8b9d781f0c2fea7177b0df6925d61a3fae22 100644 --- a/apps/web/src/components/GitActionsControl.logic.ts +++ b/apps/web/src/components/GitActionsControl.logic.ts @@ -204,7 +204,7 @@ export function resolveQuickAction( } if (hasChanges) { - if (hasOpenPr || isDefaultBranch) { + if (isDefaultBranch) { return { label: "Commit & push", disabled: false, kind: "run_action", action: "commit_push" }; } return { -- 2.54.0