sandlot/src/commands/save.ts

9 lines
272 B
TypeScript

import { requireSession, saveChanges } from "./helpers.ts"
export async function action(branch: string, message?: string) {
const { session } = await requireSession(branch)
const ok = await saveChanges(session.worktree, branch, message)
if (!ok) process.exit(1)
}