feat: add --commit-prompt switch

The new `--commit-prompt` switch allows users to specify a custom prompt for generating commit messages. This feature is implemented by adding the new argument to the argument parser in `aider/args.py` and passing it to the `Coder.create` method in `aider/main.py`.
This commit is contained in:
Paul Gauthier (aider) 2024-07-31 09:46:13 -03:00
parent adfde505d4
commit 4dfdddf0d9
2 changed files with 6 additions and 0 deletions

View file

@ -352,6 +352,11 @@ def get_parser(default_config_files, git_root):
default=False,
help="Prefix commit messages with 'aider: ' (default: False)",
)
group.add_argument(
"--commit-prompt",
metavar="PROMPT",
help="Specify a custom prompt for generating commit messages",
)
group.add_argument(
"--dry-run",
action=argparse.BooleanOptionalAction,

View file

@ -490,6 +490,7 @@ def main(argv=None, input=None, output=None, force_git_root=None, return_coder=F
attribute_committer=args.attribute_committer,
attribute_commit_message=args.attribute_commit_message,
verify_ssl=args.verify_ssl,
commit_prompt=args.commit_prompt,
)
except ValueError as err: