markdown · 2146 bytes Raw Blame History

🦜 Parrot

(noun) : birb
see also : birbb

A sassy CLI tool that mocks your failed commands with intelligent insults.

🚀 Quick Start

# Build parrot
go build -o parrot main.go

# Auto-guided setup
./parrot setup
# Interactive wizard walks you through:
# 1. Choose backend (API/Local/Fallback) 
# 2. Configure API keys or install models
# 3. Install shell hooks
# 4. Test your parrot!

Option 2: Manual Setup

# Basic functionality (works immediately)
./parrot install              # Install shell hooks
source ~/.bashrc              # For bash (or ~/.zshrc for zsh, ~/.config/fish/config.fish for fish)

# Add intelligence later
./parrot configure            # Interactive config wizard

🎯 Result

git push origin nonexistent   # Try failing a command
# 🦜 Git rejected your code harder than everyone rejects you.

🐠 Fish Shell Support

Parrot fully supports fish shell! The installation process automatically detects fish and configures it appropriately:

# Build parrot
go build -o parrot main.go

# Install (automatically detects fish)
./parrot install
# Configuration is installed to ~/.config/fish/conf.d/parrot.fish

# Restart fish or source the config
source ~/.config/fish/config.fish

Fish users get the same sassy experience with native fish syntax and hooks!

Manual Testing

Test parrot responses without shell hooks:

./parrot mock "git commit" "1"
./parrot mock "npm install" "1" 
./parrot mock "docker run" "125"

Commands Available

  • parrot mock "command" "exit_code" - Test responses
  • parrot status - Show backend status and configuration
  • parrot config init - Create sample config file
  • parrot install - Install shell hooks

Configuration Examples

# Use custom config file
PARROT_CONFIG=./my-config.toml parrot mock "git push" "1"

# Override personality
PARROT_PERSONALITY=savage parrot mock "docker run" "125"  

# Disable colors
NO_COLOR=1 parrot mock "npm install" "1"

# Enable debug mode
PARROT_DEBUG=true parrot mock "curl api.com" "7"
View source
1 # 🦜 Parrot
2 (noun) : birb
3 _see also_ : birbb
4
5 A sassy CLI tool that mocks your failed commands with intelligent insults.
6
7 ## 🚀 Quick Start
8
9 ### **Option 1: Complete Setup (Recommended)**
10 ```bash
11 # Build parrot
12 go build -o parrot main.go
13
14 # Auto-guided setup
15 ./parrot setup
16 # Interactive wizard walks you through:
17 # 1. Choose backend (API/Local/Fallback)
18 # 2. Configure API keys or install models
19 # 3. Install shell hooks
20 # 4. Test your parrot!
21 ```
22
23 ### **Option 2: Manual Setup**
24 ```bash
25 # Basic functionality (works immediately)
26 ./parrot install # Install shell hooks
27 source ~/.bashrc # For bash (or ~/.zshrc for zsh, ~/.config/fish/config.fish for fish)
28
29 # Add intelligence later
30 ./parrot configure # Interactive config wizard
31 ```
32
33 ### **🎯 Result**
34 ```bash
35 git push origin nonexistent # Try failing a command
36 # 🦜 Git rejected your code harder than everyone rejects you.
37 ```
38
39 ### **🐠 Fish Shell Support**
40
41 Parrot fully supports fish shell! The installation process automatically detects fish and configures it appropriately:
42
43 ```bash
44 # Build parrot
45 go build -o parrot main.go
46
47 # Install (automatically detects fish)
48 ./parrot install
49 # Configuration is installed to ~/.config/fish/conf.d/parrot.fish
50
51 # Restart fish or source the config
52 source ~/.config/fish/config.fish
53 ```
54
55 Fish users get the same sassy experience with native fish syntax and hooks!
56
57 ## Manual Testing
58
59 Test parrot responses without shell hooks:
60 ```bash
61 ./parrot mock "git commit" "1"
62 ./parrot mock "npm install" "1"
63 ./parrot mock "docker run" "125"
64 ```
65
66 ## Commands Available
67
68 - `parrot mock "command" "exit_code"` - Test responses
69 - `parrot status` - Show backend status and configuration
70 - `parrot config init` - Create sample config file
71 - `parrot install` - Install shell hooks
72
73 ## Configuration Examples
74
75 ```bash
76 # Use custom config file
77 PARROT_CONFIG=./my-config.toml parrot mock "git push" "1"
78
79 # Override personality
80 PARROT_PERSONALITY=savage parrot mock "docker run" "125"
81
82 # Disable colors
83 NO_COLOR=1 parrot mock "npm install" "1"
84
85 # Enable debug mode
86 PARROT_DEBUG=true parrot mock "curl api.com" "7"
87 ```