‘send_changelog.py’: Tweak message template

This commit is contained in:
Patryk Michalik
2021-06-05 08:38:18 +02:00
parent 6f63351010
commit 34d5b9d1e6

View File

@@ -11,7 +11,7 @@ telegram_ci_channel_id = os.getenv('TELEGRAM_CI_CHANNEL_ID')
repository = git.Repo('.')
commits_range = f'{github_event_before}...{github_sha}'
commits = list(repository.iter_commits(commits_range))
message = f'🔨 [{len(commits)} new commits](https://github.com/{github_repo}/compare/{commits_range}) to lawnchair:11-dev:\n'
message = f'''🔨 [{len(commits)} new {'commit' if len(commits) == 1 else 'commits'}](https://github.com/{github_repo}/compare/{commits_range}) to `lawnchair:11-dev`:'''
for commit in commits:
commit_message = commit.message.split('\n')[0].replace('_', '\\_')