(commit: CommitRow)
| 505 | |
| 506 | |
| 507 | def get_hash_or_pr_url(commit: CommitRow) -> str: |
| 508 | if not commit.pr_link: |
| 509 | return commit.commit_hash |
| 510 | matches = re.findall( |
| 511 | r'https://github.com/[^/]+/[^/]+/pull/(\d+)', |
| 512 | commit.pr_link, |
| 513 | ) |
| 514 | if not matches: |
| 515 | return commit.commit_hash |
| 516 | return f'[#{matches[0]}]({commit.pr_link})' |
| 517 | |
| 518 | |
| 519 | def markdown_entry_text(commit: CommitRow) -> str: |
no outgoing calls
no test coverage detected