def render_markdown_with_team(content, team): text = render_markdown(content) text = re.sub( RE_TICKET, r'<a href="' + team.url + r'issues/\1/" class="issue-link">#\1</a>', text) return parse_emoji(text, is_escape=False)
def render_commit_message(message, project): text = parse_emoji(message) text = re.sub(RE_PR_IN_MESSAGE, r' <a href="/%s/newpull/\1">#\1</a> ' % project.name, text) text = re.sub(RE_ISSUE_IN_MESSAGE, r' <a href="/%s/issues/\1">#\1</a> ' % project.name, text) text = text.decode('utf8') return text
def postprocess(self, text): if not text: return text text = render_checklist(text) text = parse_emoji(text, is_escape=False) return RE_USER_MENTION.sub(USER_LINK_TEXT, text)
def render_markdown_with_team(content, team): text = render_markdown(content) text = re.sub(RE_TICKET, r'<a href="' + team.url + r'issues/\1/" class="issue-link">#\1</a>', text) return parse_emoji(text, is_escape=False)