refactor: Modify offer_url method and release notes handling in main

This commit is contained in:
Paul Gauthier 2024-11-21 14:02:01 -08:00 committed by Paul Gauthier (aider)
parent c189a52e5e
commit 9eab021a50
3 changed files with 15 additions and 15 deletions

View file

@ -805,17 +805,17 @@ def main(argv=None, input=None, output=None, force_git_root=None, return_coder=F
io.tool_output('Use /help <question> for help, run "aider --help" to see cmd line args')
show = False
if args.show_release_notes is True:
show = True
elif args.show_release_notes is None and is_first_run:
io.tool_output()
show = io.confirm_ask("Would you like to see what's new in this version?")
if show:
io.tool_output(f"Opening release notes: {urls.release_notes}")
io.tool_output()
webbrowser.open(urls.release_notes)
elif args.show_release_notes is None and is_first_run:
io.tool_output()
io.offer_url(
urls.release_notes,
"Would you like to see what's new in this version?",
allow_never=False,
)
if git_root and Path.cwd().resolve() != Path(git_root).resolve():
io.tool_warning(