Skip to content

Commit 3859b3b

Browse files
committed
fix(commit): preserve context and skip-confirm flag across regenerate
When the user answers "No" at the confirmation prompt and chooses to regenerate, the recursive call to generateCommitMessageFromGitDiff forwarded only `diff`, `extraArgs`, and `fullGitMojiSpec`. Both `context` and `skipCommitConfirmation` were silently dropped, so: - `-c/--context` was honored only on the first attempt and lost on every regeneration; - `-y/--yes` was honored only on the first attempt, forcing a manual confirmation after regeneration. Forward both fields through the recursive call so the user's flags are respected for the full lifetime of the commit() invocation.
1 parent 0239d5b commit 3859b3b

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/commands/commit.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,9 @@ ${chalk.grey('——————————————————')}`
203203
await generateCommitMessageFromGitDiff({
204204
diff,
205205
extraArgs,
206-
fullGitMojiSpec
206+
context,
207+
fullGitMojiSpec,
208+
skipCommitConfirmation
207209
});
208210
}
209211
}

0 commit comments

Comments
 (0)