You opened Instagram again. Enjoy your McDonald's application.
A Python productivity tool for people who don't respond to motivation — but do respond to shame.
ragbait watches your active window in the background. The second it catches you on Instagram, TikTok, YouTube, or whatever your poison is, it automatically opens your study document and roasts you in the terminal. No blocks, no timers, no pretty graphs you'll ignore. Just consequences.
You open Instagram
↓
ragbait detects the active window title
↓
Your study doc flies open
↓
Terminal prints a personalised insult
↓
You close Instagram in shame
↓
(repeat until you pass your exams)
- Real-time window monitoring — checks your active window every few seconds
- Auto-opens your study doc — PDF, Word, anything your OS can open
- Sassy CLI remarks — a different roast every time you get caught
- Cooldown system — won't spam you every 5 seconds (60s grace period)
- Fully configurable — add any app or website to the trap list
- Session catch counter — so you can feel bad about the number at the end
- Python 3.8+
- Windows 10/11
- A study document you've been avoiding
1. Clone the repo
git clone https://github.com/RudraDudhat2509/ragbait.git
cd ragbait2. Install dependencies
pip install psutil pygetwindow3. Configure ragbait
Open ragbait.py and edit the CONFIG section at the top:
# Path to your study document
STUDY_DOC = r"C:\Users\YourName\Documents\lecture_notes.pdf"
# Days until your exam (for personalised shame)
DAYS_UNTIL_EXAM = 14
# Add or remove apps to watch
DISTRACTION_APPS = [
"instagram",
"tiktok",
"youtube",
"twitter",
"reddit",
"netflix",
"discord",
"steam",
# add more as needed
]4. Run it
python ragbait.py============================================================
🚨 RAGBAIT TRIGGERED [14:32:07]
============================================================
App caught: INSTAGRAM
You'd rather do THIS than pass your degree? Bold strategy.
↳ Opening your study doc...
✓ Study doc is now open. No excuses.
============================================================
Session catches: 3 | Still watching...
| Variable | Default | Description |
|---|---|---|
STUDY_DOC |
(required) | Full path to your study document |
CHECK_INTERVAL |
5 |
How often to check active window (seconds) |
COOLDOWN_SECONDS |
60 |
Minimum time between triggers for the same app |
DAYS_UNTIL_EXAM |
14 |
Used in shame messages |
DISTRACTION_APPS |
(see script) | List of app/window title keywords to trap |
To make ragbait start automatically with Windows:
- Press
Win + R, typeshell:startup, hit Enter - Create a shortcut to this script in that folder:
pythonw.exe "C:\full\path\to\ragbait.py"
Using pythonw.exe runs it silently in the background without a terminal window.
Q: Will it block the app?
No. ragbait doesn't block anything, it just opens your study doc in parallel. Blocking is easy to override. Shame is harder to ignore.
Q: Does it work for browsers?
Yes — if the site name appears in your browser's window title (e.g. "Instagram • Explore — Chrome"), ragbait will catch it.
Q: What if I use YouTube for studying?
Remove "youtube" from DISTRACTION_APPS in the config.
Q: Can I add my own shame messages?
Absolutely. Edit the RAGE_MESSAGES list in the script. Go wild.
PRs welcome. Especially for:
- macOS / Linux support
- Browser extension version
- A "nuclear mode" that actually blocks the app after being caught 3 times
MIT — do whatever you want with it. Just study.