diff --git a/deployer/src/deployer/analyze_pr.py b/deployer/src/deployer/analyze_pr.py index a425653cd0cd..2c72065749a2 100644 --- a/deployer/src/deployer/analyze_pr.py +++ b/deployer/src/deployer/analyze_pr.py @@ -172,10 +172,12 @@ def post_about_dangerous_content( for url in sorted(external_urls): count = external_urls[url] # Avoid GitHub mentions. + original_url = url url = url.replace('https://github.com/', 'https://redirect.github.com/') + link = f"<{url}>" if url == original_url else f"[{original_url}](<{url}>)" line = ( f" - {'🚨 ' if url.startswith('http://') else ''}" - f"<{url}> ({count} time{'' if count==1 else 's'})" + f"{link} ({count} time{'' if count==1 else 's'})" ) if diff_lines: # If this was available and it _did_ fine a URL, then