remindee-bot-0.2.2 is not a library.
remindee-bot
Telegram bot for managing reminders.
Quickstart
- Install Rust.
- Setup your bot with @botfather.
- Install the crate:
cargo install remindee-bot
- Start the bot:
remindee-bot --token <BOT TOKEN> --database <FILE>
# Alternatively, one can use environment variables:
export BOT_TOKEN=<BOT TOKEN>
export REMINDEE_DB=<FILE> # optional
remindee-bot
- Send
/startand follow the machine's instructions 🤖.
Features
One-time reminders
The format of reminder consists of three parts: <date> <time> <description>:
- Date is in either
day.month.yearoryear/month/dayformats - Time is in format
hour:minute
Examples:
- You can set reminders on specific date and time:
01.01 0:00 Happy New Year=> notify at 1st of January at 12 AM
- Some fields (day, month, year, minute, second) can be omitted. In this case the notification time will be sanely derived as the nearest time point in the future:
8 wake up(notify at 8 AM today if it's 0:00-7:59 AM, tomorrow otherwise)1 0 ++month(notify on the first day of the next month at 12 AM)
Recurring reminders
Recurring reminders is an extended format, thus everything from the previous section applies here. Now there are three parts <date pattern> <time pattern> <description>:
- Date pattern is in either
dateordate_from-date_until/date_divisorformats (can specify multiple with,separator) - Date divisor is in either
1y2m3dormon-tue,thu,sat-sun-like formats - Time pattern is in either
timeortime_from-time_until/time_divisorformats (can specify multiple with,separator) - Time divisor is in
1h2m3s-like format
Examples:
- Notify every one and a half hours from 10 AM to 8 PM on weekdays:
-/mon-fri 10-20/1h30m take a breakOn Monday-Friday at 10-20 every 1hour30mins take a break
- Notify on every Sunday from the 1st of April to the 1st of May at 15:00:
1.04-1.05/sun at 15:30 clean the room01.04-01.05 every Sunday at 15:30 clean the room
- Notify on the 20th day of every month at 10 AM:
20/1m 10 submit meter readings
Countdown
This kind of reminders is in <duration> <description> format and sets a timer for the specified duration.
- Duration is in
1y2mo3w4d5h6m7sformat
Examples:
- Notify after 5 minutes:
5m grab teaIn 5mins grab teaafter 5minutes grab tea
Cron
NOTE: Originally cron-like reminders were the only way to create a recurring reminder, but one can still use them with crontab-like syntax:
55 10 * * 1-5 go to school(at 10:30 AM every weekday)45 10-19 * * 1-6 break for 15 minutes(at 10:45, 11:45, ..., 19:45 from Monday to Saturday)