@devries-cameron20 / t3code Mirror · read-only / commits / 97d04c3bb7
Fork 0

The best way to control Claude Code, Codex and more from any computer or phone

Mirrored from https://github.com/Camo67/t3code.git

Synced Nov 22, 02:00 UTC

fix(forgejo): tea's `pull` and `m` aliases count as shell merges (#32401)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>

Felix Laga committed Nov 7, 2026 at 21:41 UTC 97d04c3bb791f47d9893da5a33c51e94a9011345
2 files changed +17 -1
packages/source-control-forgejo/src/shared/definition.test.ts
+15
@@ -120,6 +120,21 @@ describe("Forgejo remotes", () => {
120 });
121 });
122
123 +describe("Forgejo CLI commands", () => {
124 + it("recognizes shell merges and closes under every spelling tea accepts", () => {
125 + for (const command of [
126 + "tea pulls merge 7",
127 + "tea pull merge 7",
128 + "tea pr m 7",
129 + "tea pull close 7",
130 + "fj pr close 7",
131 + ]) {
132 + expect(definition.changeRequestCloseCommand.test(command), command).toBe(true);
133 + }
134 + expect(definition.changeRequestCloseCommand.test("tea pull checkout 7")).toBe(false);
135 + });
136 +});
137 +
138 describe("Forgejo change request host", () => {
139 it("keeps an HTTP remote's port, because a server's identity includes it", () => {
140 const project = identity("http://forge.example:3000/git/team/repo.git");
packages/source-control-forgejo/src/shared/definition.ts
+2 -1
@@ -93,7 +93,8 @@ export const definition = defineSourceControl({
93 repositoryUrl
94 ? `git fetch '${repositoryUrl.replaceAll("'", "'\\''")}' ${changeRequestHeadRef(number)} && git checkout -B pulls/${number} FETCH_HEAD`
95 : null,
96 - changeRequestCloseCommand: /\b(?:tea\s+(?:pr|pulls)|fj\s+pr)\s+(?:merge|close)\b/u,
96 + // tea also takes `pull` for `pulls` and `m` for `merge`.
97 + changeRequestCloseCommand: /\b(?:tea\s+(?:pr|pulls?)|fj\s+pr)\s+(?:merge|m|close)\b/u,
98 authorProfileUrl: () => null,
99 hardLineBreaks: true,
100 // Forgejo refuses a change request review without a summary, even with inline comments.