aboutsummaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorGravatar jesopo2018-11-18 10:20:16 +0000
committerGravatar jesopo2018-11-18 10:20:16 +0000
commit6fbbcace66125578ca70f6b2e2f88ae72f19b9f8 (patch)
tree089f41e14490019d564b9fb62efcd1eba4251f4c /modules
parentAdd help/usage to factoids.py (diff)
signature
Make branch names in commit notifications blueified
Diffstat (limited to 'modules')
-rw-r--r--modules/github.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/github.py b/modules/github.py
index 4368d476..f48d86c4 100644
--- a/modules/github.py
+++ b/modules/github.py
@@ -111,7 +111,8 @@ class Module(ModuleManager.BaseModule):
def push(self, event, full_name, data):
outputs = []
- branch = data["ref"].split("/", 2)[2]
+ branch = utils.irc.color(data["ref"].split("/", 2)[2],
+ utils.consts.BLUE)
if len(data["commits"]) <= 3:
for commit in data["commits"]:
id = self._short_hash(commit["id"])
@@ -127,7 +128,6 @@ class Module(ModuleManager.BaseModule):
outputs.append("[%s/%s/%s files] commit by %s to %s: %s - %s"
% (added, removed, modified, author, branch, message, url))
else:
- branch = data["ref"].split("/", 2)[2]
first_id = self._short_hash(data["before"])
last_id = self._short_hash(data["commits"][-1]["id"])
pusher = utils.irc.bold(data["pusher"]["name"])