ra2-eva-cursor-hooks 1.0.0 → 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +95 -0
  2. package/package.json +3 -2
package/README.md ADDED
@@ -0,0 +1,95 @@
1
+ # Red Alert 2 EVA Cursor Hooks
2
+
3
+ Nostalgic Red Alert 2 EVA voice lines for Cursor IDE agent events. Transform your coding sessions with iconic audio feedback from the classic RTS game.
4
+
5
+ ## Features
6
+
7
+ - **17 hook events** with custom EVA voice lines
8
+ - **Allied & Soviet factions** - alternates based on hour (odd = Allied, even = Soviet)
9
+ - **Audio queue** - prevents overlapping sounds when parallel tools execute
10
+ - **Easy install** - one command via npx
11
+
12
+ ## Sound Mappings
13
+
14
+ | Event | Sound |
15
+ |-------|-------|
16
+ | Session Start | "Establishing battlefield control. Stand by." |
17
+ | Session End | "Battle control terminated." |
18
+ | Before Shell | "Building." |
19
+ | After Shell | "Unit ready." |
20
+ | Before Read File | "Training." |
21
+ | After File Edit | "Unit promoted." |
22
+ | Before MCP | "Upgrade in progress." |
23
+ | After MCP | "New technology acquired." |
24
+ | Before Prompt | "New mission objective received." / "New construction options." |
25
+ | Tool Failure | "Unit lost." |
26
+ | Delete File | "Unit lost." |
27
+ | Stop (completed) | "Construction complete." / "Primary objective achieved." |
28
+ | Stop (aborted) | "Cancelled." |
29
+ | Stop (error) | "Cannot deploy here." |
30
+ | Subagent Start | "Reinforcements have arrived." |
31
+ | Subagent Stop | "Objective achieved." |
32
+ | Agent Thought | "Incoming transmission." |
33
+ | Context Compact | "Low power." |
34
+
35
+ ## Installation
36
+
37
+ ### Via npx (recommended)
38
+
39
+ ```bash
40
+ npx ra2-eva-cursor-hooks
41
+ ```
42
+
43
+ Or use the shorter alias:
44
+
45
+ ```bash
46
+ npx ra2-eva
47
+ ```
48
+
49
+ ### Manual Installation
50
+
51
+ ```bash
52
+ git clone https://github.com/toubatbrian/cursor-hooks.git
53
+ cd cursor-hooks
54
+ ./install.sh
55
+ ```
56
+
57
+ ## Prerequisites
58
+
59
+ - **Bun runtime** - required to run the TypeScript hooks
60
+ ```bash
61
+ curl -fsSL https://bun.sh/install | bash
62
+ ```
63
+ - **macOS** - uses `afplay` for audio playback
64
+
65
+ ## Uninstall
66
+
67
+ ```bash
68
+ npx ra2-eva-cursor-hooks --uninstall
69
+ ```
70
+
71
+ ## Faction Selection
72
+
73
+ The EVA voice alternates between factions based on the current hour:
74
+
75
+ - **Odd hours** (1, 3, 5, 7, 9, 11, 13, 15, 17, 19, 21, 23) → **Allied EVA** (English)
76
+ - **Even hours** (0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 22) → **Soviet EVA** (Russian accent)
77
+
78
+ ## How It Works
79
+
80
+ This package installs Cursor hooks that:
81
+
82
+ 1. Listen for agent events (tool use, file edits, shell commands, etc.)
83
+ 2. Play appropriate Red Alert 2 EVA voice lines via `afplay`
84
+ 3. Queue audio to prevent overlapping when multiple events fire simultaneously
85
+ 4. Return proper JSON responses to allow Cursor to continue
86
+
87
+ Files are installed to `~/.cursor/hooks/ra2-eva/` and configured in `~/.cursor/hooks.json`.
88
+
89
+ ## Audio Credits
90
+
91
+ Voice lines are from **Command & Conquer: Red Alert 2** by Westwood Studios / EA Games. This is a fan project for nostalgic/educational purposes.
92
+
93
+ ## License
94
+
95
+ MIT
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ra2-eva-cursor-hooks",
3
- "version": "1.0.0",
3
+ "version": "1.0.1",
4
4
  "description": "Red Alert 2 EVA voice lines for Cursor IDE hooks - nostalgic audio feedback for your coding sessions",
5
5
  "keywords": [
6
6
  "cursor",
@@ -25,7 +25,8 @@
25
25
  "files": [
26
26
  "bin/",
27
27
  "src/",
28
- "assets/"
28
+ "assets/",
29
+ "README.md"
29
30
  ],
30
31
  "engines": {
31
32
  "node": ">=18.0.0"