feat: Add model and API key validation with documentation link

This commit is contained in:
Paul Gauthier 2025-01-31 08:59:26 -08:00 committed by Paul Gauthier (aider)
parent b4b54d1796
commit 31d23bc9a7
4 changed files with 42 additions and 3 deletions

View file

@ -765,6 +765,10 @@ def main(argv=None, input=None, output=None, force_git_root=None, return_coder=F
f"Found {env_key} so using {model_name} since no --model was specified."
)
break
if not args.model:
self.io.tool_error("You need to specify a --model and an --api-key to use.")
io.offer_url(urls.models_and_keys, "Open documentation url for more info?")
return 1
main_model = models.Model(
args.model,