Merge pull request #320 from tarnhold/master

htmlreport: Generate file list sorted by file name
This commit is contained in:
Daniel Marjamäki 2014-05-26 18:34:51 +02:00
commit dc798baa37
1 changed files with 2 additions and 2 deletions

View File

@ -273,7 +273,7 @@ if __name__ == '__main__':
# Generate a HTML file with syntax highlighted source code for each
# file that contains one or more errors.
print('Processing errors')
for filename, data in files.items():
for filename, data in sorted(files.items()):
htmlfile = data['htmlfile']
errors = data['errors']
@ -327,7 +327,7 @@ if __name__ == '__main__':
output_file.write('<table>')
output_file.write(
'<tr><th>Line</th><th>Id</th><th>Severity</th><th>Message</th></tr>')
for filename, data in files.items():
for filename, data in sorted(files.items()):
output_file.write(
"<tr><td colspan='4'><a href='%s'>%s</a></td></tr>" %
(data['htmlfile'], filename))