@ankushch12/console-pets
v1.0.0
Published
Tiny ASCII animals that live in your terminal and react to your code activity!
Maintainers
Readme
🐱 Console Pets
Tiny ASCII animals that live in your terminal and react to your code!
Installation
npm install -g @ankushch12/console-petsUsage
As a Background Daemon (Recommended)
This mode lets a pet live in your terminal and react to your activity across all sessions. It starts automatically!
Add to your shell:
For Zsh (Mac default): Add this to your ~/.zshrc:
source $(npm root -g)/@ankushch12/console-pets/shell-prompt.shFor Bash: Add this to your ~/.bashrc:
source $(npm root -g)/@ankushch12/console-pets/shell-prompt.shThat's it! Every time you open a terminal, the pet will check if it needs to wake up and start watching your work.
As a CLI wrapper
console-pets -- npm test
console-pets -- node app.jsLive Watch Mode
See your pet move in real-time in any terminal window:
console-pets watchHow it works
Console Pets works in three parts:
- The Brain (daemon.js): A lightweight background process that monitors your activity.
- The Eye (monitor.js): Watches for file changes in your project and keyboard activity in your shell.
- The Display (shell-prompt.sh): A tiny script that reads the pet's current state and injects it into your terminal prompt.
Features
- Idle - Sleeping when no activity for 5+ seconds
- Working - Typing when you code or run commands
- Success - Celebrating when process exits successfully
- Error - Hiding when errors occur
- Thinking - Loading animation
License
This project is licensed under the MIT License - see the LICENSE file for details.
