Show More
@@ -267,12 +267,20 b' class SlackIntegrationType(IntegrationTy' | |||
|
267 | 267 | title = render_with_traceback(template, data=data) |
|
268 | 268 | |
|
269 | 269 | repo_push_template = Template(textwrap.dedent(r''' |
|
270 | %for branch, branch_commits in branches_commits.items(): | |
|
271 | ${len(branch_commits['commits'])} ${'commit' if len(branch_commits['commits']) == 1 else 'commits'} on branch: <${branch_commits['branch']['url']}|${branch_commits['branch']['name']}> | |
|
272 | %for commit in branch_commits['commits']: | |
|
270 | <% | |
|
271 | def branch_text(branch): | |
|
272 | if branch: | |
|
273 | return 'on branch: <{}|{}>'.format(branch_commits['branch']['url'], branch_commits['branch']['name']) | |
|
274 | else: | |
|
275 | ## case for SVN no branch push... | |
|
276 | return 'to trunk' | |
|
277 | %> \ | |
|
278 | % for branch, branch_commits in branches_commits.items(): | |
|
279 | ${len(branch_commits['commits'])} ${'commit' if len(branch_commits['commits']) == 1 else 'commits'} ${branch_text(branch)} | |
|
280 | % for commit in branch_commits['commits']: | |
|
273 | 281 | `<${commit['url']}|${commit['short_id']}>` - ${commit['message_html']|html_to_slack_links} |
|
274 | %endfor | |
|
275 | %endfor | |
|
282 | % endfor | |
|
283 | % endfor | |
|
276 | 284 | ''')) |
|
277 | 285 | |
|
278 | 286 | text = render_with_traceback( |
General Comments 0
You need to be logged in to leave comments.
Login now