[gen-changelog] Make subject line always come first

* gen-changelog.py (process_commit): In changelog entries with an
	empty body, make sure the subject line comes first.

Signed-off-by: Dodji Seketeli <dodji@redhat.com>
This commit is contained in:
Dodji Seketeli 2014-11-18 16:00:46 +01:00
parent 86aa07c5c9
commit d1ee1202ce

View File

@ -75,13 +75,15 @@ def process_commit(lines, files):
top_line = ' '.join(fields)
print top_line.strip()
print
if not fileincommit:
for f in files:
print '\t* %s:' % f
if subject_line_index > 0:
print '\t', lines[subject_line_index]
if not fileincommit:
for f in files:
print '\t* %s:' % f
print
if first_cl_body_line_index > 0:
for l in lines[first_cl_body_line_index:]:
if l.startswith('Signed-off-by:'):