mirror of
https://github.com/di-sukharev/opencommit.git
synced 2026-04-20 03:02:51 -04:00
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.
This commit is contained in:
@@ -203,7 +203,9 @@ ${chalk.grey('——————————————————')}`
|
||||
await generateCommitMessageFromGitDiff({
|
||||
diff,
|
||||
extraArgs,
|
||||
fullGitMojiSpec
|
||||
context,
|
||||
fullGitMojiSpec,
|
||||
skipCommitConfirmation
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user