feat(walkthrough): plan-then-explain generation with selectable diff sources

This commit is contained in:
Chris Scott committed 2026-10-08 15:53:49 -04:00
1 parent aeea96b466
commit 88b3543dc1
35 files changed
+2583 -609

No files matched your search

+12 -2
View File
@@ -1,12 +1,22 @@
import { z } from 'zod'
import { getBranchNameError } from '../utils/repo'
const branchNameSchema = z.string().trim().superRefine((value, ctx) => {
function addBranchNameIssue(value: string, ctx: z.RefinementCtx) {
const error = getBranchNameError(value)
if (error) {
ctx.addIssue({ code: 'custom', message: error })
}
})
}
const branchNameSchema = z.string().trim().superRefine(addBranchNameIssue)
export const gitRefSchema = z
.string()
.trim()
.min(1)
.max(200)
.regex(/^\S+$/)
.superRefine(addBranchNameIssue)
export const RenameBranchRequestSchema = z.object({
from: branchNameSchema,