Skip to content

Commit 2ab7895

Browse files
garyshengsebwalle
andcommitted
Merge PR #32: Add round-robin pack rotation mode
Adds deterministic round-robin option for pack_rotation by @sebwalle, so each session gets the next pack in order instead of random. New config: "pack_rotation_mode": "round-robin" (default: "random"). Resolves VERSION conflict (1.3.0 vs 1.4.1 → 1.4.2). Co-Authored-By: Sebastian Walleby <sebwalle@users.noreply.github.com>
2 parents 64124d2 + 3846023 commit 2ab7895

207 files changed

Lines changed: 1239 additions & 49 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

README.md

Lines changed: 25 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# peon-ping
22

3-
![macOS](https://img.shields.io/badge/macOS-blue) ![WSL2](https://img.shields.io/badge/WSL2-blue)
3+
![macOS](https://img.shields.io/badge/macOS-blue) ![WSL2](https://img.shields.io/badge/WSL2-blue) ![Linux](https://img.shields.io/badge/Linux-blue)
44
![License](https://img.shields.io/badge/license-MIT-green)
55
![Claude Code](https://img.shields.io/badge/Claude_Code-hook-ffab01)
66

@@ -16,7 +16,15 @@ Claude Code doesn't notify you when it finishes or needs permission. You tab awa
1616
curl -fsSL https://raw.githubusercontent.com/tonyyont/peon-ping/main/install.sh | bash
1717
```
1818

19-
One command. Takes 10 seconds. macOS and WSL2 (Windows). Re-run to update (sounds and config preserved).
19+
One command. Takes 10 seconds. macOS, WSL2 (Windows), and Linux. Re-run to update (sounds and config preserved).
20+
21+
**Project-local install** — installs into `.claude/` in the current project instead of `~/.claude/`:
22+
23+
```bash
24+
curl -fsSL https://raw.githubusercontent.com/tonyyont/peon-ping/main/install.sh | bash -s -- --local
25+
```
26+
27+
Local installs don't add the `peon` CLI alias or shell completions — use `/peon-ping-toggle` inside Claude Code instead.
2028

2129
## What you'll hear
2230

@@ -86,8 +94,19 @@ Edit `~/.claude/hooks/peon-ping/config.json`:
8694
| `peasant` | Human Peasant (Warcraft III) | "Yes, milord?", "Job's done!", "Ready, sir." | [@thomasKn](https://github.com/thomasKn) |
8795
| `peasant_fr` | Human Peasant (Warcraft III, French) | "Oui, monseigneur?", "C'est fait!", "Prêt, monsieur." | [@thomasKn](https://github.com/thomasKn) |
8896
| `ra2_soviet_engineer` | Soviet Engineer (Red Alert 2) | "Tools ready", "Yes, commander", "Engineering" | [@msukkari](https://github.com/msukkari) |
97+
| `peon_ru` | Orc Peon (Warcraft III, Russian) | "Готов вкалывать!", "Работа, работа.", "Оки-доки." | [@maksimfedin](https://github.com/maksimfedin) |
98+
| `peasant_ru` | Human Peasant (Warcraft III, Russian) | "Да, господин?", "Готово.", "Ну, я пошёл!" | [@maksimfedin](https://github.com/maksimfedin) |
99+
| `acolyte_ru` | Undead Acolyte (Warcraft III, Russian) | "Моя жизнь за Нер'зула!", "Да, повелитель.", "Тени служат мне." | [@maksimfedin](https://github.com/maksimfedin) |
100+
| `tf2_engineer` | Engineer (Team Fortress 2) | "Sentry going up.", "Nice work!", "Cowboy up!" | [@Arie](https://github.com/Arie) |
89101
| `sc_battlecruiser` | Battlecruiser (StarCraft) | "Battlecruiser operational", "Make it happen", "Engage" | [@garysheng](https://github.com/garysheng) |
90102
| `sc_kerrigan` | Sarah Kerrigan (StarCraft) | "I gotcha", "What now?", "Easily amused, huh?" | [@garysheng](https://github.com/garysheng) |
103+
| `glados` | GLaDOS (Portal) | "Oh, it's you.", "You monster.", "Your entire team is dead." | [@DoubleGremlin181](https://github.com/DoubleGremlin181) |
104+
| `sc_terran` | Terran Units Mixed (StarCraft) | SCV, Firebat, Medic, Siege Tank, Science Vessel | [@workdd](https://github.com/workdd) |
105+
| `sc_scv` | SCV (StarCraft) | "Good to go, sir", "Affirmative", "I read you" | [@workdd](https://github.com/workdd) |
106+
| `sc_firebat` | Firebat (StarCraft) | "Need a light?", "Ready to roast!", "Fueled up!" | [@workdd](https://github.com/workdd) |
107+
| `sc_medic` | Medic (StarCraft) | "The doctor is in", "Where does it hurt?", "All patched up!" | [@workdd](https://github.com/workdd) |
108+
| `sc_tank` | Siege Tank (StarCraft) | "Ready to roll out", "Absolutely", "Done and done" | [@workdd](https://github.com/workdd) |
109+
| `sc_vessel` | Science Vessel (StarCraft) | "Explorer reporting", "Receiving", "Affirmative" | [@workdd](https://github.com/workdd) |
91110

92111
Switch packs from the CLI:
93112

@@ -108,18 +127,19 @@ Want to add your own pack? See [CONTRIBUTING.md](CONTRIBUTING.md).
108127
## Uninstall
109128

110129
```bash
111-
bash ~/.claude/hooks/peon-ping/uninstall.sh
130+
bash ~/.claude/hooks/peon-ping/uninstall.sh # global
131+
bash .claude/hooks/peon-ping/uninstall.sh # project-local
112132
```
113133

114134
## Requirements
115135

116-
- macOS (uses `afplay` and AppleScript) or WSL2 (uses PowerShell `MediaPlayer` and WinForms)
136+
- macOS (uses `afplay` and AppleScript), WSL2 (uses PowerShell `MediaPlayer` and WinForms), or Linux (uses `pw-play`/`paplay`/`ffplay`/`mpv`/`aplay` and `notify-send`)
117137
- Claude Code with hooks support
118138
- python3
119139

120140
## How it works
121141

122-
`peon.sh` is a Claude Code hook registered for `SessionStart`, `UserPromptSubmit`, `Stop`, and `Notification` events. On each event it maps to a sound category, picks a random voice line (avoiding repeats), plays it via `afplay` (macOS) or PowerShell `MediaPlayer` (WSL2), and updates your Terminal tab title.
142+
`peon.sh` is a Claude Code hook registered for `SessionStart`, `UserPromptSubmit`, `Stop`, and `Notification` events. On each event it maps to a sound category, picks a random voice line (avoiding repeats), plays it via `afplay` (macOS), PowerShell `MediaPlayer` (WSL2), or `paplay`/`ffplay`/`mpv`/`aplay` (Linux), and updates your Terminal tab title.
123143

124144
Sound files are property of their respective publishers (Blizzard Entertainment, EA) and are included in the repo for convenience.
125145

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
1.3.0
1+
1.4.2

completions.fish

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
# peon-ping tab completion for fish shell
2+
3+
# Top-level options (no repeated suggestions)
4+
complete -c peon -f
5+
complete -c peon -l pause -d "Pause sound notifications"
6+
complete -c peon -l resume -d "Resume sound notifications"
7+
complete -c peon -l toggle -d "Toggle sound notifications"
8+
complete -c peon -l status -d "Show current status"
9+
complete -c peon -l packs -d "List available sound packs"
10+
complete -c peon -l pack -d "Switch active sound pack" -r -a "(
11+
set -l packs_dir (set -q CLAUDE_PEON_DIR; and echo \$CLAUDE_PEON_DIR; or echo \$HOME/.claude/hooks/peon-ping)/packs
12+
if test -d \$packs_dir
13+
for manifest in \$packs_dir/*/manifest.json
14+
basename (dirname \$manifest)
15+
end
16+
end
17+
)"
18+
complete -c peon -l help -d "Show help message"
14.6 KB
Binary file not shown.
16.8 KB
Binary file not shown.
16 KB
Binary file not shown.
16.4 KB
Binary file not shown.
46.2 KB
Binary file not shown.
32.7 KB
Binary file not shown.

docs/index.html

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1141,6 +1141,50 @@ <h2 class="section-title">Choose your character</h2>
11411141
</div>
11421142
</div>
11431143
</div>
1144+
<!-- Pack 6: TF2 Engineer -->
1145+
<div class="carousel-slide" data-pack="tf2_engineer">
1146+
<div class="pack-card-full">
1147+
<div class="pack-header">
1148+
<div class="pack-badge">New</div>
1149+
<div class="pack-name">TF2 Engineer</div>
1150+
<div class="pack-game">Team Fortress 2</div>
1151+
<code class="pack-id">tf2_engineer</code>
1152+
<div class="pack-credit">Added by <a href="https://github.com/Arie">@Arie</a></div>
1153+
</div>
1154+
<div class="pack-sounds">
1155+
<button class="pack-sound-btn" data-src="audio/Engineer_battlecry03.mp3" aria-label="Play: Cowboy up!">
1156+
<span class="pack-sound-icon">&#9654;</span>
1157+
<span class="pack-sound-quote">"Cowboy up!"</span>
1158+
<span class="pack-sound-cat">greeting</span>
1159+
</button>
1160+
<button class="pack-sound-btn" data-src="audio/Engineer_autobuildingsentry01.mp3" aria-label="Play: Sentry going up.">
1161+
<span class="pack-sound-icon">&#9654;</span>
1162+
<span class="pack-sound-quote">"Sentry going up."</span>
1163+
<span class="pack-sound-cat">acknowledge</span>
1164+
</button>
1165+
<button class="pack-sound-btn" data-src="audio/Eng_quest_complete_easy_01.mp3" aria-label="Play: Nice work!">
1166+
<span class="pack-sound-icon">&#9654;</span>
1167+
<span class="pack-sound-quote">"Nice work!"</span>
1168+
<span class="pack-sound-cat">complete</span>
1169+
</button>
1170+
<button class="pack-sound-btn" data-src="audio/Engineer_autodestroyedsentry01.mp3" aria-label="Play: Sentry down!">
1171+
<span class="pack-sound-icon">&#9654;</span>
1172+
<span class="pack-sound-quote">"Sentry down!"</span>
1173+
<span class="pack-sound-cat">error</span>
1174+
</button>
1175+
<button class="pack-sound-btn" data-src="audio/Engineer_wranglekills01.mp3" aria-label="Play: This thing ain't on auto-pilot, son!">
1176+
<span class="pack-sound-icon">&#9654;</span>
1177+
<span class="pack-sound-quote">"Ain't on auto-pilot, son!"</span>
1178+
<span class="pack-sound-cat">permission</span>
1179+
</button>
1180+
<button class="pack-sound-btn" data-src="audio/Engineer_goldenwrenchkill04.mp3" aria-label="Play: Erectin' a statue of a moron.">
1181+
<span class="pack-sound-icon">&#9654;</span>
1182+
<span class="pack-sound-quote">"Erectin' a statue of a moron."</span>
1183+
<span class="pack-sound-cat">annoyed</span>
1184+
</button>
1185+
</div>
1186+
</div>
1187+
</div>
11441188
</div>
11451189

11461190
<button class="carousel-arrow carousel-next" aria-label="Next pack">
@@ -1154,6 +1198,7 @@ <h2 class="section-title">Choose your character</h2>
11541198
<button class="carousel-dot" data-index="2" aria-label="Soviet Engineer"></button>
11551199
<button class="carousel-dot" data-index="3" aria-label="Battlecruiser"></button>
11561200
<button class="carousel-dot" data-index="4" aria-label="Sarah Kerrigan"></button>
1201+
<button class="carousel-dot" data-index="5" aria-label="TF2 Engineer"></button>
11571202
</div>
11581203

11591204
<div class="contribute-cta">

0 commit comments

Comments
 (0)