mirror of
https://github.com/SpiceBot/SpiceBot.git
synced 2026-11-10 21:50:59 -05:00
18 lines
505 B
Python
18 lines
505 B
Python
# coding=utf-8
|
|
|
|
from __future__ import unicode_literals, absolute_import, division, print_function
|
|
|
|
import sopel.module
|
|
|
|
import time
|
|
|
|
import sopel_modules.SpiceBot as SpiceBot
|
|
|
|
|
|
@SpiceBot.events.check_ready([SpiceBot.events.BOT_LOADED])
|
|
@SpiceBot.prerun('nickname')
|
|
@sopel.module.nickname_commands('uptime')
|
|
def bot_command_uptime(bot, trigger, botcom):
|
|
timesince = str(SpiceBot.humanized_time(time.time() - SpiceBot.events.BOT_UPTIME)) + " ago."
|
|
bot.osd("I have been running since " + timesince)
|