rmmh / skybot

Python IRC bot
https://github.com/rmmh/skybot/wiki
The Unlicense
249 stars 170 forks source link

Remindme plugin that highlights you after a specific time period with a specific message #156

Open mezmor opened 8 years ago

mezmor commented 8 years ago

The usage is similar to youtube timestamps: " .remindme 4h30m20s go to work damn it! " will highlight you after 4 hours, 30 minutes, and 20 seconds with the message "go to work damn it!" Users can also list their active reminders and delete their reminders by targeting the reminder text. This allows for multiple deletion so they need to be careful. The users can create up to (default) 10 maximum reminders. The reminders can not be longer than (default) 5 years.

Reminders are saved to the database with their expire time. Every time a privmsg event occurs, it checks the time to expire for every reminder. Every reminder that has a time to expire less than the threading_threshold will have a thread spawned and its database active_thread field updated.

The default value for the threading_threshold is 5 minutes.