oh-my-claude-sisyphus 3.5.5 → 3.5.7

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 (63) hide show
  1. package/README.md +58 -343
  2. package/commands/mcp-setup.md +75 -64
  3. package/commands/omc-setup.md +51 -0
  4. package/dist/__tests__/analytics/tokscale-adapter.test.d.ts +2 -0
  5. package/dist/__tests__/analytics/tokscale-adapter.test.d.ts.map +1 -0
  6. package/dist/__tests__/analytics/tokscale-adapter.test.js +79 -0
  7. package/dist/__tests__/analytics/tokscale-adapter.test.js.map +1 -0
  8. package/dist/analytics/cost-estimator.d.ts +14 -0
  9. package/dist/analytics/cost-estimator.d.ts.map +1 -1
  10. package/dist/analytics/cost-estimator.js +65 -0
  11. package/dist/analytics/cost-estimator.js.map +1 -1
  12. package/dist/analytics/index.d.ts +1 -0
  13. package/dist/analytics/index.d.ts.map +1 -1
  14. package/dist/analytics/index.js +4 -0
  15. package/dist/analytics/index.js.map +1 -1
  16. package/dist/analytics/query-engine.d.ts +3 -0
  17. package/dist/analytics/query-engine.d.ts.map +1 -1
  18. package/dist/analytics/query-engine.js +87 -0
  19. package/dist/analytics/query-engine.js.map +1 -1
  20. package/dist/analytics/token-tracker.d.ts +3 -0
  21. package/dist/analytics/token-tracker.d.ts.map +1 -1
  22. package/dist/analytics/token-tracker.js +89 -0
  23. package/dist/analytics/token-tracker.js.map +1 -1
  24. package/dist/analytics/tokscale-adapter.d.ts +71 -0
  25. package/dist/analytics/tokscale-adapter.d.ts.map +1 -0
  26. package/dist/analytics/tokscale-adapter.js +223 -0
  27. package/dist/analytics/tokscale-adapter.js.map +1 -0
  28. package/dist/analytics/types.d.ts +17 -0
  29. package/dist/analytics/types.d.ts.map +1 -1
  30. package/dist/analytics/types.js +5 -0
  31. package/dist/analytics/types.js.map +1 -1
  32. package/dist/cli/analytics.js +35 -0
  33. package/dist/cli/analytics.js.map +1 -1
  34. package/dist/cli/commands/agents.d.ts.map +1 -1
  35. package/dist/cli/commands/agents.js +4 -2
  36. package/dist/cli/commands/agents.js.map +1 -1
  37. package/dist/cli/commands/stats.d.ts.map +1 -1
  38. package/dist/cli/commands/stats.js +6 -1
  39. package/dist/cli/commands/stats.js.map +1 -1
  40. package/dist/cli/index.js +95 -35
  41. package/dist/cli/index.js.map +1 -1
  42. package/dist/cli/utils/tokscale-launcher.d.ts +18 -0
  43. package/dist/cli/utils/tokscale-launcher.d.ts.map +1 -0
  44. package/dist/cli/utils/tokscale-launcher.js +64 -0
  45. package/dist/cli/utils/tokscale-launcher.js.map +1 -0
  46. package/dist/features/auto-update.js +5 -5
  47. package/dist/features/auto-update.js.map +1 -1
  48. package/dist/hud/types.d.ts +6 -2
  49. package/dist/hud/types.d.ts.map +1 -1
  50. package/dist/hud/types.js.map +1 -1
  51. package/dist/hud/usage-api.d.ts.map +1 -1
  52. package/dist/hud/usage-api.js +13 -1
  53. package/dist/hud/usage-api.js.map +1 -1
  54. package/docs/ARCHITECTURE.md +80 -397
  55. package/docs/FEATURES.md +396 -1981
  56. package/docs/MIGRATION.md +4 -4
  57. package/docs/REFERENCE.md +545 -0
  58. package/docs/SYNC-SYSTEM.md +6 -6
  59. package/package.json +2 -1
  60. package/scripts/sync-metadata.ts +2 -2
  61. package/skills/mcp-setup/SKILL.md +63 -75
  62. package/skills/omc-setup/SKILL.md +51 -0
  63. package/docs/FULL-README.md +0 -1001
@@ -9,7 +9,7 @@ Configure Model Context Protocol (MCP) servers to extend Claude Code's capabilit
9
9
 
10
10
  ## Overview
11
11
 
12
- MCP servers provide additional tools that Claude Code agents can use. This skill helps you configure popular MCP servers in your `~/.claude/settings.json`.
12
+ MCP servers provide additional tools that Claude Code agents can use. This skill helps you configure popular MCP servers using the `claude mcp add` command-line interface.
13
13
 
14
14
  ## Step 1: Show Available MCP Servers
15
15
 
@@ -55,95 +55,51 @@ Do you have a GitHub Personal Access Token?
55
55
  - Enter your token, or type 'skip' to configure later
56
56
  ```
57
57
 
58
- ## Step 3: Update settings.json
58
+ ## Step 3: Add MCP Servers Using CLI
59
59
 
60
- Read the current `~/.claude/settings.json` and add/update the `mcpServers` section.
60
+ Use the `claude mcp add` command to configure each MCP server. The CLI automatically handles settings.json updates and merging.
61
61
 
62
62
  ### Context7 Configuration:
63
- ```json
64
- {
65
- "mcpServers": {
66
- "context7": {
67
- "command": "npx",
68
- "args": ["-y", "@upstash/context7-mcp"]
69
- }
70
- }
71
- }
63
+ ```bash
64
+ claude mcp add context7 -- npx -y @upstash/context7-mcp
72
65
  ```
73
66
 
74
67
  ### Exa Web Search Configuration:
75
- ```json
76
- {
77
- "mcpServers": {
78
- "exa": {
79
- "command": "npx",
80
- "args": ["-y", "exa-mcp-server"],
81
- "env": {
82
- "EXA_API_KEY": "<user-provided-key>"
83
- }
84
- }
85
- }
86
- }
68
+ ```bash
69
+ claude mcp add -e EXA_API_KEY=<user-provided-key> exa -- npx -y exa-mcp-server
87
70
  ```
88
71
 
89
72
  ### Filesystem Configuration:
90
- ```json
91
- {
92
- "mcpServers": {
93
- "filesystem": {
94
- "command": "npx",
95
- "args": ["-y", "@modelcontextprotocol/server-filesystem", "<allowed-directories>"]
96
- }
97
- }
98
- }
73
+ ```bash
74
+ claude mcp add filesystem -- npx -y @modelcontextprotocol/server-filesystem <allowed-directories>
99
75
  ```
100
76
 
101
77
  ### GitHub Configuration:
102
- ```json
103
- {
104
- "mcpServers": {
105
- "github": {
106
- "command": "docker",
107
- "args": ["run", "-i", "--rm", "-e", "GITHUB_PERSONAL_ACCESS_TOKEN", "ghcr.io/github/github-mcp-server"],
108
- "env": {
109
- "GITHUB_PERSONAL_ACCESS_TOKEN": "<user-provided-token>"
110
- }
111
- }
112
- }
113
- }
114
- ```
115
-
116
- > Note: GitHub MCP requires Docker. Alternatively, configure as a remote URL: https://api.githubcopilot.com/mcp/
117
78
 
118
- ## Step 4: Merge Configuration
119
-
120
- When updating settings.json:
121
-
122
- 1. Read existing file: `~/.claude/settings.json`
123
- 2. Parse as JSON (handle comments with jsonc-parser if needed)
124
- 3. Merge new `mcpServers` entries with existing ones (don't overwrite user's other MCP servers)
125
- 4. Write back to file with proper formatting
79
+ **Option 1: Docker (local)**
80
+ ```bash
81
+ claude mcp add -e GITHUB_PERSONAL_ACCESS_TOKEN=<user-provided-token> github -- docker run -i --rm -e GITHUB_PERSONAL_ACCESS_TOKEN ghcr.io/github/github-mcp-server
82
+ ```
126
83
 
84
+ **Option 2: HTTP (remote)**
127
85
  ```bash
128
- # Backup existing settings first
129
- cp ~/.claude/settings.json ~/.claude/settings.json.bak 2>/dev/null || true
86
+ claude mcp add --transport http github https://api.githubcopilot.com/mcp/
130
87
  ```
131
88
 
132
- Use the Edit tool or Write tool to update the settings file, preserving existing configuration.
89
+ > Note: Docker option requires Docker installed. HTTP option is simpler but may have different capabilities.
133
90
 
134
- ## Step 5: Verify Installation
91
+ ## Step 4: Verify Installation
135
92
 
136
93
  After configuration, verify the MCP servers are properly set up:
137
94
 
138
95
  ```bash
139
- # Check if settings.json has mcpServers
140
- grep -q "mcpServers" ~/.claude/settings.json && echo "MCP servers configured" || echo "Configuration may have failed"
141
-
142
- # List configured servers
143
- node -e "const s = require('$HOME/.claude/settings.json'); console.log('Configured MCP servers:', Object.keys(s.mcpServers || {}).join(', ') || 'none')"
96
+ # List configured MCP servers
97
+ claude mcp list
144
98
  ```
145
99
 
146
- ## Step 6: Show Completion Message
100
+ This will display all configured MCP servers and their status.
101
+
102
+ ## Step 5: Show Completion Message
147
103
 
148
104
  ```
149
105
  MCP Server Configuration Complete!
@@ -154,6 +110,7 @@ CONFIGURED SERVERS:
154
110
  NEXT STEPS:
155
111
  1. Restart Claude Code for changes to take effect
156
112
  2. The configured MCP tools will be available to all agents
113
+ 3. Run `claude mcp list` to verify configuration
157
114
 
158
115
  USAGE TIPS:
159
116
  - Context7: Ask about library documentation (e.g., "How do I use React hooks?")
@@ -162,11 +119,15 @@ USAGE TIPS:
162
119
  - GitHub: Interact with GitHub repos, issues, and PRs
163
120
 
164
121
  TROUBLESHOOTING:
165
- - If MCP servers don't appear, check ~/.claude/settings.json for syntax errors
166
- - Ensure you have Node.js 18+ installed for npx commands
122
+ - If MCP servers don't appear, run `claude mcp list` to check status
123
+ - Ensure you have Node.js 18+ installed for npx-based servers
124
+ - For GitHub Docker option, ensure Docker is installed and running
167
125
  - Run /oh-my-claudecode:doctor to diagnose issues
168
126
 
169
- To add more MCP servers later, run: /oh-my-claudecode:mcp-setup
127
+ MANAGING MCP SERVERS:
128
+ - Add more servers: /oh-my-claudecode:mcp-setup or `claude mcp add ...`
129
+ - List servers: `claude mcp list`
130
+ - Remove a server: `claude mcp remove <server-name>`
170
131
  ```
171
132
 
172
133
  ## Custom MCP Server
@@ -175,23 +136,50 @@ If user selects "Custom":
175
136
 
176
137
  Ask for:
177
138
  1. Server name (identifier)
178
- 2. Command to run (e.g., `npx`, `node`, path to executable)
179
- 3. Arguments (comma-separated)
180
- 4. Environment variables (optional, key=value pairs)
139
+ 2. Transport type: `stdio` (default) or `http`
140
+ 3. For stdio: Command and arguments (e.g., `npx my-mcp-server`)
141
+ 4. For http: URL (e.g., `https://example.com/mcp`)
142
+ 5. Environment variables (optional, key=value pairs)
143
+ 6. HTTP headers (optional, for http transport only)
144
+
145
+ Then construct and run the appropriate `claude mcp add` command:
146
+
147
+ **For stdio servers:**
148
+ ```bash
149
+ # Without environment variables
150
+ claude mcp add <server-name> -- <command> [args...]
151
+
152
+ # With environment variables
153
+ claude mcp add -e KEY1=value1 -e KEY2=value2 <server-name> -- <command> [args...]
154
+ ```
181
155
 
182
- Then add to mcpServers section accordingly.
156
+ **For HTTP servers:**
157
+ ```bash
158
+ # Basic HTTP server
159
+ claude mcp add --transport http <server-name> <url>
160
+
161
+ # HTTP server with headers
162
+ claude mcp add --transport http --header "Authorization: Bearer <token>" <server-name> <url>
163
+ ```
183
164
 
184
165
  ## Common Issues
185
166
 
186
167
  ### MCP Server Not Loading
187
168
  - Ensure Node.js 18+ is installed
188
169
  - Check that npx is available in PATH
189
- - Verify no JSON syntax errors in settings.json
170
+ - Run `claude mcp list` to verify server status
171
+ - Check server logs for errors
190
172
 
191
173
  ### API Key Issues
192
174
  - Exa: Verify key at https://dashboard.exa.ai
193
- - GitHub: Ensure token has required scopes
175
+ - GitHub: Ensure token has required scopes (repo, read:org)
176
+ - Re-run `claude mcp add` with correct credentials if needed
194
177
 
195
178
  ### Agents Still Using Built-in Tools
196
179
  - Restart Claude Code after configuration
197
180
  - The built-in websearch will be deprioritized when exa is configured
181
+ - Run `claude mcp list` to confirm servers are active
182
+
183
+ ### Removing or Updating a Server
184
+ - Remove: `claude mcp remove <server-name>`
185
+ - Update: Remove the old server, then add it again with new configuration
@@ -266,6 +266,45 @@ echo "Default execution mode set to: USER_CHOICE"
266
266
 
267
267
  **Note**: This preference ONLY affects generic keywords ("fast", "parallel"). Explicit keywords ("ulw", "eco") always override this preference.
268
268
 
269
+ ## Step 3.8: Install CLI Analytics Tools (Optional)
270
+
271
+ The OMC CLI provides standalone token analytics commands (`omc stats`, `omc agents`, `omc tui`).
272
+
273
+ Ask user: "Would you like to install the OMC CLI for standalone analytics? (Recommended for tracking token usage and costs)"
274
+
275
+ **Options:**
276
+ 1. **Yes (Recommended)** - Install CLI tools globally for `omc stats`, `omc agents`, etc.
277
+ 2. **No** - Skip CLI installation, use only plugin skills
278
+
279
+ ### If User Chooses YES:
280
+
281
+ ```bash
282
+ # Check for bun (preferred) or npm
283
+ if command -v bun &> /dev/null; then
284
+ echo "Installing OMC CLI via bun..."
285
+ bun install -g oh-my-claudecode
286
+ elif command -v npm &> /dev/null; then
287
+ echo "Installing OMC CLI via npm..."
288
+ npm install -g oh-my-claudecode
289
+ else
290
+ echo "ERROR: Neither bun nor npm found. Please install Node.js or Bun first."
291
+ exit 1
292
+ fi
293
+
294
+ # Verify installation
295
+ if command -v omc &> /dev/null; then
296
+ echo "✓ OMC CLI installed successfully!"
297
+ echo " Try: omc stats, omc agents, omc tui"
298
+ else
299
+ echo "⚠ CLI installed but 'omc' not in PATH."
300
+ echo " You may need to restart your terminal or add npm/bun global bin to PATH."
301
+ fi
302
+ ```
303
+
304
+ ### If User Chooses NO:
305
+
306
+ Skip this step. User can install later with `npm install -g oh-my-claudecode`.
307
+
269
308
  ## Step 4: Verify Plugin Installation
270
309
 
271
310
  ```bash
@@ -329,6 +368,12 @@ Run /oh-my-claudecode:mcp-setup to add tools like web search, GitHub, etc.
329
368
  HUD STATUSLINE:
330
369
  The status bar now shows OMC state. Restart Claude Code to see it.
331
370
 
371
+ CLI ANALYTICS (if installed):
372
+ - omc - Full dashboard (stats + agents + cost)
373
+ - omc stats - View token usage and costs
374
+ - omc agents - See agent breakdown by cost
375
+ - omc tui - Launch interactive TUI dashboard
376
+
332
377
  That's it! Just use Claude Code normally.
333
378
  ```
334
379
 
@@ -359,6 +404,12 @@ MAGIC KEYWORDS (power-user shortcuts):
359
404
  HUD STATUSLINE:
360
405
  The status bar now shows OMC state. Restart Claude Code to see it.
361
406
 
407
+ CLI ANALYTICS (if installed):
408
+ - omc - Full dashboard (stats + agents + cost)
409
+ - omc stats - View token usage and costs
410
+ - omc agents - See agent breakdown by cost
411
+ - omc tui - Launch interactive TUI dashboard
412
+
362
413
  Your workflow won't break - it just got easier!
363
414
  ```
364
415