Initial commit: project scaffold, full spec, database schema, bot and cron
- SPEC.md: full project specification from design discussion - schema.sql: SQLite database schema - db.py: database wrapper with all query functions - bot.py: telegram bot entrypoint - commands.py: all command handlers with admin/creator guards - cron.py: daily reminder job - requirements.txt: python-telegram-bot, dateparser - README.md, CONTRIBUTING.md - .gitignore
This commit is contained in:
74
README.md
Normal file
74
README.md
Normal file
@@ -0,0 +1,74 @@
|
||||
# JIGAIDO
|
||||
|
||||
> Named after Nanami Kento's Cursed Technique restriction. Suppresses power during normal hours, exerts it during overtime.
|
||||
|
||||
A lightweight bounty tracker for Telegram groups and individuals. Track obligations, deadlines, and tasks with optional reminders.
|
||||
|
||||
## Features
|
||||
|
||||
- **Group bounties**: Each Telegram group has its own bounty list
|
||||
- **Personal bounties**: Private DM bounty list for individuals
|
||||
- **Admin-only posting**: Only group admins can add/update/delete bounties
|
||||
- **Universal tracking**: Any member can track bounties to their personal list
|
||||
- **Due date reminders**: Daily cron notifies users when bounties are due within 7 days
|
||||
- **Free-form dates**: Natural language due dates (`"tomorrow"`, `"in 3 days"`, `"april 15"`)
|
||||
- **Link deduplication**: No duplicate links within the same group
|
||||
- **Zero infrastructure**: SQLite + Python, deploys on any $5 VPS
|
||||
|
||||
## Quick Start
|
||||
|
||||
```bash
|
||||
# Install dependencies
|
||||
pip install -r requirements.txt
|
||||
|
||||
# Set bot token
|
||||
export JIGAIDO_BOT_TOKEN="your:token_here"
|
||||
|
||||
# Initialize database and start bot
|
||||
python bot.py
|
||||
```
|
||||
|
||||
## Commands
|
||||
|
||||
| Command | Where | Who | Description |
|
||||
|---|---|---|---|
|
||||
| `/bounty` | Group / DM | Anyone | List all bounties |
|
||||
| `/my` | Group / DM | Anyone | List your tracked bounties |
|
||||
| `/add <text> [link] [due]` | Group | Admin | Add bounty |
|
||||
| `/add <text> [link] [due]` | DM | Anyone | Add personal bounty |
|
||||
| `/update <id> [text] [link] [due]` | Group | Admin | Update bounty |
|
||||
| `/delete <id>` | Group | Admin | Delete bounty |
|
||||
| `/track <id>` | Group / DM | Anyone | Track a bounty |
|
||||
| `/untrack <id>` | Group / DM | Anyone | Stop tracking |
|
||||
| `/admin_add <user>` | Group | Creator | Promote to admin |
|
||||
| `/admin_remove <user>` | Group | Creator | Demote admin |
|
||||
| `/start` | Group / DM | Anyone | Re-initialize |
|
||||
| `/help` | Anywhere | Anyone | Show help |
|
||||
|
||||
## Reminders
|
||||
|
||||
Schedule a daily cron job:
|
||||
|
||||
```bash
|
||||
# crontab -e
|
||||
0 9 * * * cd /path/to/jigaido && JIGAIDO_BOT_TOKEN="your:token" python -m cron
|
||||
```
|
||||
|
||||
Or via systemd timer (see `cron.py`).
|
||||
|
||||
## Project Structure
|
||||
|
||||
```
|
||||
jigaido/
|
||||
├── bot.py # Telegram bot entrypoint
|
||||
├── db.py # SQLite database wrapper
|
||||
├── schema.sql # Database schema
|
||||
├── cron.py # Daily reminder job
|
||||
├── commands.py # Command handlers
|
||||
├── requirements.txt
|
||||
└── SPEC.md # Full specification
|
||||
```
|
||||
|
||||
## License
|
||||
|
||||
MIT
|
||||
Reference in New Issue
Block a user