release notes: skip the release edit when the notes are already grouped

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Chris LuandClaude Opus 5.5 committed 2026-11-17 19:42:39 -08:00
1 parent f1eac773cc
commit fb3a41f224
1 file changed
+2 -1
@@ -280,9 +280,10 @@ def main():
notes = regroup(body, pr_files)
except ValueError as e:
sys.exit("release %s: %s" % (args.tag, e))
sys.stdout.write(notes)
if notes.strip() == body.replace("\r\n", "\n").strip():
print("release %s: notes already grouped, nothing to change" % args.tag, file=sys.stderr)
sys.stdout.write(notes)
return
if failed and args.write:
sys.exit("release %s: not writing, could not read the files of %s"
% (args.tag, ", ".join("#%d" % n for n in failed)))