Skip to content

Commit

Permalink
Escape ` * and _ in github output
Browse files Browse the repository at this point in the history
  • Loading branch information
jenshnielsen committed Oct 25, 2014
1 parent 7ae0939 commit 84d971f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tools/github_stats.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,10 +104,10 @@ def report(issues, show_urls=False):
for i in issues:
role = 'ghpull' if 'merged_at' in i else 'ghissue'
print(u'* :%s:`%d`: %s' % (role, i['number'],
i['title'].replace(u'`', u'``')))
i['title'].replace(u'`', u'\`').replace(u'*',u'\*').replace(u'_',u'\_')))
else:
for i in issues:
print(u'* %d: %s' % (i['number'], i['title'].replace(u'`', u'``')))
print(u'* %d: %s' % (i['number'], i['title'].replace(u'`', u'\`').replace(u'*',u'\*').replace(u'_',u'\_')))

#-----------------------------------------------------------------------------
# Main script
Expand Down

0 comments on commit 84d971f

Please sign in to comment.