From e073832e4228511761d3f5c5a6c10aeb4b3a44cf Mon Sep 17 00:00:00 2001 From: "James E. Blair" Date: Tue, 24 Aug 2021 09:41:20 -0700 Subject: [PATCH] Make commit and patchset comments nicer Rather than display the /PATCHSET_LEVEL and /COMMIT_MSG fake filenames, translate those to nice strings like the web ui does. Change-Id: I225c8e2ea9763f9dadbefc4a23329efe0f97d899 --- gertty/view/change.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/gertty/view/change.py b/gertty/view/change.py index c2d3009..e2afce6 100644 --- a/gertty/view/change.py +++ b/gertty/view/change.py @@ -494,6 +494,10 @@ class ChangeMessageBox(mywid.HyperText): if inline_comments: comment_text.append(u'\n') for key, value in inline_comments.items(): + if key == '/PATCHSET_LEVEL': + key = 'Patchset' + if key == '/COMMIT_MSG': + key = 'Commit message' comment_text.append(('filename-inline-comment', u'%s' % key)) for patchset, line, comment in value: location_str = ''