I Built a Tamagotchi That Judges Your GitHub Activity 🐾 (and it's brutally honest)
Source: Dev.to
Introduction
You know that guilt when you haven’t pushed code in a few days? Imagine that feeling had a face—a tiny ASCII octocat staring at you from your terminal, slowly starving to death.
cli‑pet is a virtual pet that lives in your terminal and is powered by your real GitHub activity. Your commits are food, green CI builds keep it healthy, merged PRs are pure serotonin, and coding streaks act as energy drinks. Stop coding for a few days and your pet literally withers away; its stats decay in real‑time, and the ASCII art shifts from a happy bouncing creature to a sad, hungry mess with (;.;) eyes.
I didn’t build a productivity tool. I built emotional manipulation as a service. And honestly? It works. I’ve never been more motivated to push commits.
You can adopt one of four pets:
- 🐱 Cat – purrs when your CI is green
- 🐶 Dog – fetches your GitHub notifications (get it?)
- 🐉 Dragon – breathes fire on failing tests
- 🐙 Octocat – the ultimate GitHub companion
How cli‑pet works
Stats
Your pet has four stats, each mapped to real GitHub data:
| Stat | What feeds it | What happens when it drops |
|---|---|---|
| 🍕 Hunger | Your commits | Pet starts begging you to write code |
| ❤️ Health | CI/CD success rate | Failing pipelines → sick pet |
| 😊 Happiness | Merged PRs & code reviews | Pet thrives on collaboration |
| ⚡ Energy | Coding streak days | Consistency is key |
Stats decay over time, so a weekend of ghosting your repo will return a dramatically different ASCII creature.
Commands
cli-pet adopt # 🏠 Choose your pet and name it
cli-pet status # 👀 Check on your little buddy
cli-pet feed # 🍕 Fetch GitHub data and feed your pet
cli-pet play # 🎮 Play a number‑guessing game together
cli-pet stats # 📊 See the full GitHub activity breakdown
cli-pet tips # 🧠 Get personalized coding advice from your pet
Tips feature
The tips command is a favorite. Your pet analyzes your coding patterns and offers relevant advice:
- Haven’t reviewed any PRs lately? The pet will call you out.
- CI is flaky? It’ll suggest pre‑commit hooks.
- 7‑day streak? It’ll remind you that rest is productive too.
Repository
🔗 GitHub Repository:
Installation
npx cli-pet
Requires Node.js 18+ and either gh auth login or a GITHUB_TOKEN environment variable.
Development with Copilot CLI
Real talk: this project would have taken me far longer without Copilot CLI.
- Idea & Architecture – I described a “virtual pet but GitHub” and Copilot helped break it into modules: pet state machine, GitHub activity fetcher, ASCII art renderer, CLI commands.
- Stat Decay & Mood Math – Iteratively refined equations for hunger decrease per hour, handling neglect over multiple days.
- GitHub API Integration – Copilot guided me through Octokit to fetch push events, calculate CI success rates, and compute coding streaks from activity dates.
- Streak Calculation – Implemented backward date traversal to detect consecutive days; Copilot handled the tricky date math.
- ASCII Art Generation – Produced 4 pet species × 8 moods = 32 variants; Copilot generated base art, I tweaked for distinct moods (e.g., the sad cat with
(;.;)eyes). - Debugging – Resolved ESM module issues, TypeScript errors with Chalk, and module resolution quirks in seconds thanks to Copilot’s contextual suggestions.
- Iterative Pair‑Programming – Copilot read files, ran commands, spotted errors, and applied fixes across the codebase, effectively acting as a pair programmer at 3× speed.
The result? A fully functional terminal pet that gamifies real work without feeling like a forced chore.
Conclusion
If you haven’t adopted a terminal pet yet, what are you waiting for? Run cli-pet adopt and give your coding habits the accountability partner they deserve. 🐾
And if your pet dies… that’s on you. I just built the thing.