Remove added/removed/modified counts from commits (github)
This commit is contained in:
parent
2affba99ca
commit
4aa86f865c
1 changed files with 4 additions and 16 deletions
|
@ -468,14 +468,9 @@ class Module(ModuleManager.BaseModule):
|
||||||
author = utils.irc.bold(data["pusher"]["name"])
|
author = utils.irc.bold(data["pusher"]["name"])
|
||||||
url = self._short_url(COMMIT_URL % (full_name, id))
|
url = self._short_url(COMMIT_URL % (full_name, id))
|
||||||
|
|
||||||
added = self._added(len(commit["added"]))
|
|
||||||
removed = self._removed(len(commit["removed"]))
|
|
||||||
modified = self._modified(len(commit["modified"]))
|
|
||||||
|
|
||||||
outputs.append(
|
outputs.append(
|
||||||
"%s %spushed to %s [%s/%s/%s files] %s - %s"
|
"%s %spushed to %s: %s - %s"
|
||||||
% (author, forced, branch, added, removed, modified,
|
% (author, forced, branch, message, url))
|
||||||
message, url))
|
|
||||||
else:
|
else:
|
||||||
first_id = data["before"]
|
first_id = data["before"]
|
||||||
last_id = data["commits"][-1]["id"]
|
last_id = data["commits"][-1]["id"]
|
||||||
|
@ -483,15 +478,8 @@ class Module(ModuleManager.BaseModule):
|
||||||
url = self._short_url(
|
url = self._short_url(
|
||||||
COMMIT_RANGE_URL % (full_name, first_id, last_id))
|
COMMIT_RANGE_URL % (full_name, first_id, last_id))
|
||||||
|
|
||||||
commits = data["commits"]
|
outputs.append("%s %spushed %d commits to %s - %s"
|
||||||
added = self._added(len(self._flat_unique(commits, "added")))
|
% (pusher, forced, len(data["commits"]), branch, url))
|
||||||
removed = self._removed(len(self._flat_unique(commits, "removed")))
|
|
||||||
modified = self._modified(len(self._flat_unique(commits,
|
|
||||||
"modified")))
|
|
||||||
|
|
||||||
outputs.append("%s %spushed %d commits to %s [%s/%s/%s files] - %s"
|
|
||||||
% (pusher, forced, len(data["commits"]), branch,
|
|
||||||
added, removed, modified, url))
|
|
||||||
|
|
||||||
return outputs
|
return outputs
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue