diff options
author | kongr45gpen <electrovesta@gmail.com> | 2014-04-25 16:18:15 +0300 |
---|---|---|
committer | kongr45gpen <electrovesta@gmail.com> | 2014-04-25 16:18:15 +0300 |
commit | 59aa66b0b8e1e17255effc3a4a6e32994be8d177 (patch) | |
tree | d795e500931c29f4f516489eb654cd08b6bd0720 /local/utility.py | |
parent | 29f8b71c828f1c1d423e1f9f032db3c574eb499a (diff) | |
download | supybot_github-59aa66b0b8e1e17255effc3a4a6e32994be8d177.tar.gz supybot_github-59aa66b0b8e1e17255effc3a4a6e32994be8d177.tar.bz2 supybot_github-59aa66b0b8e1e17255effc3a4a6e32994be8d177.zip |
Add basic status message handler (fixes #3)
Diffstat (limited to 'local/utility.py')
-rw-r--r-- | local/utility.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/local/utility.py b/local/utility.py index c6a6c60..4fba906 100644 --- a/local/utility.py +++ b/local/utility.py @@ -38,20 +38,21 @@ def maxLen(msg, maxn=400): def colorAction(action): """Give an action string (e.g. created, edited) and get a nice IRC colouring""" - if action == "created" or action == "opened" or action == "tagged": + if action == "created" or action == "opened" or action == "tagged" or action == "success": return ircutils.bold(ircutils.mircColor(action, "green")) if action == "deleted" or action == "closed" or action == "re-tagged" or \ action == "deleted tag" or action == "failed" or action == "still failing": return ircutils.bold(ircutils.mircColor(action, "red")) if action == "merged": return ircutils.bold(ircutils.mircColor(action, "light blue")) - if action == "reopened": + if action == "reopened" or action == "pending": return ircutils.bold(ircutils.mircColor(action, "blue")) if action == "forced the creation of" or action == "forced the deletion of": return ircutils.bold(ircutils.mircColor(action,"brown")) return action def getShortURL(longurl): + """ Returns a short URL generated by git.io""" if configValue("shortURL") is False: url = longurl else: |