feat: Set placeholder with args in /context command

This commit is contained in:
Paul Gauthier (aider) 2025-03-22 18:33:50 -07:00
parent c7fe86021c
commit be87ff0193

View file

@ -1167,12 +1167,22 @@ class Commands:
user_msg = args user_msg = args
coder.run(user_msg) coder.run(user_msg)
raise SwitchCoder( # When using context command, set the placeholder to the args
edit_format=self.coder.edit_format, if edit_format == "context" and args.strip():
summarize_from_coder=False, raise SwitchCoder(
from_coder=coder, edit_format=self.coder.edit_format,
show_announcements=False, summarize_from_coder=False,
) from_coder=coder,
show_announcements=False,
placeholder=args,
)
else:
raise SwitchCoder(
edit_format=self.coder.edit_format,
summarize_from_coder=False,
from_coder=coder,
show_announcements=False,
)
def get_help_md(self): def get_help_md(self):
"Show help about all commands in markdown" "Show help about all commands in markdown"