From c16e84fda7c5f8b094ca89573e7bd97c499db605 Mon Sep 17 00:00:00 2001 From: Laurent Peuch Date: Wed, 6 May 2020 22:22:01 +0200 Subject: [PATCH] [mod] also list branches on which pipeline is --- server.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/server.py b/server.py index 92765f6..f29a714 100644 --- a/server.py +++ b/server.py @@ -462,10 +462,11 @@ async def github(request): url = request.json["commit"]["html_url"] commit_message = request.json["commit"]["commit"]["message"].replace("\n", " ") commit_author = request.json["commit"]["committer"]["login"] + branches = ", ".join((x["name"] for x in request.json["commit"]["branches"])) if state not in ("success", "pending"): await notify( - f'[{repository}] {description} {target_url} on commit {url} "{commit_message}" by @{commit_author}' + f'[{repository}] {description} {target_url} on commit {url} "{commit_message}" by @{commit_author} on branche{"s" if len(branches) > 1 else ""} {branches}' ) else: print(