Refactor to apps/ structure

JIGAIDO is now a platform with apps/ as the container.
All telegram-bot files moved to apps/telegram-bot/:
- bot.py, commands.py, cron.py, db.py, schema.sql
- requirements.txt, .env.example, README.md
- Root now holds SPEC.md, README.md, CONTRIBUTING.md only.

Structure:
jigaido/
├── apps/
│   └── telegram-bot/
└── SPEC.md, README.md, CONTRIBUTING.md
This commit is contained in:
shokollm
2026-04-01 08:05:10 +00:00
parent be5fe04a90
commit 9f0ad2d404
12 changed files with 70 additions and 61 deletions

View File

@@ -0,0 +1,44 @@
# Telegram Bot
A Telegram bot for managing and tracking bounties in groups and DMs.
## Setup
```bash
cd apps/telegram-bot
cp .env.example .env
# Edit .env and add your bot token
pip install -r requirements.txt
```
## Run
```bash
python bot.py
```
## Reminders
Schedule a daily cron job:
```bash
# crontab -e
0 9 * * * cd /path/to/jigaido/apps/telegram-bot && JIGAIDO_BOT_TOKEN="..." python cron.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 |