# HG changeset patch # User Teemu Piippo # Date 1417275951 18000 # Node ID 27294de7b0d30fb134e3765581aa1e567f695a44 # Parent e4891ab34fb168901933aada5af01d81778d67a5# Parent 2bad379cd4164b4fd1a62eda58098f32c009e6cc - merged diff -r 2bad379cd416 -r 27294de7b0d3 mod_admin.py --- a/mod_admin.py Sat Nov 29 17:45:20 2014 +0200 +++ b/mod_admin.py Sat Nov 29 10:45:51 2014 -0500 @@ -26,13 +26,6 @@ }, { - 'name': 'update', - 'description': 'Checks for updates on the bot', - 'args': None, - 'level': 'admin' - }, - - { 'name': 'die', 'description': 'Shuts the bot down', 'args': None, @@ -52,18 +45,3 @@ def cmd_die (bot, **rest): quit() - -def cmd_update (bot, replyto, **rest): - try: - repo = hgapi.Repo ('.') - r1 = repo.hg_id() - repo.hg_pull() - repo.hg_update('tip', True) - r2 = repo.hg_id() - if r1 != r2: - bot.privmsg (replyto, 'Updated to %s, restarting...' % r2) - bot.restart() - else: - bot.privmsg (replyto, 'Up to date at %s.' % r2) - except hgapi.HgException as e: - command_error ('Update failed: %s' % str (e)) \ No newline at end of file