oh-my-claude-sisyphus 3.8.16 → 3.9.0

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 (160) hide show
  1. package/.claude-plugin/marketplace.json +1 -1
  2. package/.claude-plugin/plugin.json +1 -1
  3. package/.mcp.json +1 -1
  4. package/agents/analyst.md +41 -0
  5. package/agents/architect.md +45 -0
  6. package/agents/critic.md +42 -0
  7. package/agents/deep-executor.md +193 -0
  8. package/agents/planner.md +82 -0
  9. package/bridge/mcp-server.cjs +181 -181
  10. package/dist/__tests__/agent-registry.test.js +1 -1
  11. package/dist/__tests__/installer.test.js +8 -8
  12. package/dist/__tests__/installer.test.js.map +1 -1
  13. package/dist/__tests__/omc-tools-server.test.js +2 -2
  14. package/dist/__tests__/omc-tools-server.test.js.map +1 -1
  15. package/dist/__tests__/skills.test.js +5 -4
  16. package/dist/__tests__/skills.test.js.map +1 -1
  17. package/dist/agents/deep-executor.d.ts +15 -0
  18. package/dist/agents/deep-executor.d.ts.map +1 -0
  19. package/dist/agents/deep-executor.js +47 -0
  20. package/dist/agents/deep-executor.js.map +1 -0
  21. package/dist/agents/definitions.d.ts +15 -0
  22. package/dist/agents/definitions.d.ts.map +1 -1
  23. package/dist/agents/definitions.js +25 -0
  24. package/dist/agents/definitions.js.map +1 -1
  25. package/dist/agents/index.d.ts +1 -0
  26. package/dist/agents/index.d.ts.map +1 -1
  27. package/dist/agents/index.js +1 -0
  28. package/dist/agents/index.js.map +1 -1
  29. package/dist/cli/commands/doctor-conflicts.d.ts +55 -0
  30. package/dist/cli/commands/doctor-conflicts.d.ts.map +1 -0
  31. package/dist/cli/commands/doctor-conflicts.js +261 -0
  32. package/dist/cli/commands/doctor-conflicts.js.map +1 -0
  33. package/dist/cli/index.js +16 -1
  34. package/dist/cli/index.js.map +1 -1
  35. package/dist/features/auto-update.d.ts +12 -0
  36. package/dist/features/auto-update.d.ts.map +1 -1
  37. package/dist/features/auto-update.js +4 -1
  38. package/dist/features/auto-update.js.map +1 -1
  39. package/dist/features/context-injector/types.d.ts +1 -1
  40. package/dist/features/context-injector/types.d.ts.map +1 -1
  41. package/dist/hooks/__tests__/bridge.test.d.ts +2 -0
  42. package/dist/hooks/__tests__/bridge.test.d.ts.map +1 -0
  43. package/dist/hooks/__tests__/bridge.test.js +199 -0
  44. package/dist/hooks/__tests__/bridge.test.js.map +1 -0
  45. package/dist/hooks/beads-context/__tests__/index.test.d.ts +2 -0
  46. package/dist/hooks/beads-context/__tests__/index.test.d.ts.map +1 -0
  47. package/dist/hooks/beads-context/__tests__/index.test.js +150 -0
  48. package/dist/hooks/beads-context/__tests__/index.test.js.map +1 -0
  49. package/dist/hooks/beads-context/constants.d.ts +3 -0
  50. package/dist/hooks/beads-context/constants.d.ts.map +1 -0
  51. package/dist/hooks/beads-context/constants.js +35 -0
  52. package/dist/hooks/beads-context/constants.js.map +1 -0
  53. package/dist/hooks/beads-context/index.d.ts +21 -0
  54. package/dist/hooks/beads-context/index.d.ts.map +1 -0
  55. package/dist/hooks/beads-context/index.js +62 -0
  56. package/dist/hooks/beads-context/index.js.map +1 -0
  57. package/dist/hooks/beads-context/types.d.ts +7 -0
  58. package/dist/hooks/beads-context/types.d.ts.map +1 -0
  59. package/dist/hooks/beads-context/types.js +2 -0
  60. package/dist/hooks/beads-context/types.js.map +1 -0
  61. package/dist/hooks/bridge.d.ts +4 -0
  62. package/dist/hooks/bridge.d.ts.map +1 -1
  63. package/dist/hooks/bridge.js +76 -23
  64. package/dist/hooks/bridge.js.map +1 -1
  65. package/dist/hooks/clear-suggestions/constants.d.ts +54 -0
  66. package/dist/hooks/clear-suggestions/constants.d.ts.map +1 -0
  67. package/dist/hooks/clear-suggestions/constants.js +102 -0
  68. package/dist/hooks/clear-suggestions/constants.js.map +1 -0
  69. package/dist/hooks/clear-suggestions/index.d.ts +61 -0
  70. package/dist/hooks/clear-suggestions/index.d.ts.map +1 -0
  71. package/dist/hooks/clear-suggestions/index.js +282 -0
  72. package/dist/hooks/clear-suggestions/index.js.map +1 -0
  73. package/dist/hooks/clear-suggestions/triggers.d.ts +65 -0
  74. package/dist/hooks/clear-suggestions/triggers.d.ts.map +1 -0
  75. package/dist/hooks/clear-suggestions/triggers.js +222 -0
  76. package/dist/hooks/clear-suggestions/triggers.js.map +1 -0
  77. package/dist/hooks/clear-suggestions/types.d.ts +92 -0
  78. package/dist/hooks/clear-suggestions/types.d.ts.map +1 -0
  79. package/dist/hooks/clear-suggestions/types.js +9 -0
  80. package/dist/hooks/clear-suggestions/types.js.map +1 -0
  81. package/dist/hooks/index.d.ts +1 -0
  82. package/dist/hooks/index.d.ts.map +1 -1
  83. package/dist/hooks/index.js +3 -0
  84. package/dist/hooks/index.js.map +1 -1
  85. package/dist/hooks/permission-handler/index.d.ts.map +1 -1
  86. package/dist/hooks/permission-handler/index.js +3 -1
  87. package/dist/hooks/permission-handler/index.js.map +1 -1
  88. package/dist/hooks/setup/index.d.ts.map +1 -1
  89. package/dist/hooks/setup/index.js +12 -5
  90. package/dist/hooks/setup/index.js.map +1 -1
  91. package/dist/hooks/subagent-tracker/index.d.ts.map +1 -1
  92. package/dist/hooks/subagent-tracker/index.js +25 -9
  93. package/dist/hooks/subagent-tracker/index.js.map +1 -1
  94. package/dist/index.js +1 -1
  95. package/dist/index.js.map +1 -1
  96. package/dist/installer/__tests__/claude-md-merge.test.d.ts +6 -0
  97. package/dist/installer/__tests__/claude-md-merge.test.d.ts.map +1 -0
  98. package/dist/installer/__tests__/claude-md-merge.test.js +220 -0
  99. package/dist/installer/__tests__/claude-md-merge.test.js.map +1 -0
  100. package/dist/installer/__tests__/safe-installer.test.d.ts +6 -0
  101. package/dist/installer/__tests__/safe-installer.test.d.ts.map +1 -0
  102. package/dist/installer/__tests__/safe-installer.test.js +172 -0
  103. package/dist/installer/__tests__/safe-installer.test.js.map +1 -0
  104. package/dist/installer/hooks.d.ts.map +1 -1
  105. package/dist/installer/hooks.js +3 -1
  106. package/dist/installer/hooks.js.map +1 -1
  107. package/dist/installer/index.d.ts +27 -1
  108. package/dist/installer/index.d.ts.map +1 -1
  109. package/dist/installer/index.js +209 -85
  110. package/dist/installer/index.js.map +1 -1
  111. package/dist/mcp/omc-tools-server.d.ts +1 -1
  112. package/dist/mcp/omc-tools-server.d.ts.map +1 -1
  113. package/dist/mcp/omc-tools-server.js +3 -3
  114. package/dist/mcp/omc-tools-server.js.map +1 -1
  115. package/dist/mcp/standalone-server.js +1 -1
  116. package/dist/mcp/standalone-server.js.map +1 -1
  117. package/dist/verification/tier-selector.d.ts +40 -0
  118. package/dist/verification/tier-selector.d.ts.map +1 -0
  119. package/dist/verification/tier-selector.js +95 -0
  120. package/dist/verification/tier-selector.js.map +1 -0
  121. package/dist/verification/tier-selector.test.d.ts +2 -0
  122. package/dist/verification/tier-selector.test.d.ts.map +1 -0
  123. package/dist/verification/tier-selector.test.js +282 -0
  124. package/dist/verification/tier-selector.test.js.map +1 -0
  125. package/docs/AGENTS.md +1 -1
  126. package/docs/CLAUDE.md +90 -378
  127. package/docs/partials/agent-tiers.md +165 -0
  128. package/docs/partials/features.md +131 -0
  129. package/docs/partials/mode-hierarchy.md +120 -0
  130. package/docs/partials/mode-selection-guide.md +82 -0
  131. package/docs/partials/verification-tiers.md +107 -0
  132. package/docs/shared/agent-tiers.md +165 -0
  133. package/docs/shared/features.md +131 -0
  134. package/docs/shared/mode-hierarchy.md +120 -0
  135. package/docs/shared/mode-selection-guide.md +82 -0
  136. package/docs/shared/verification-tiers.md +107 -0
  137. package/package.json +4 -3
  138. package/scripts/compose-docs.mjs +44 -0
  139. package/scripts/keyword-detector.mjs +13 -3
  140. package/skills/deep-executor/SKILL.md +50 -0
  141. package/skills/ecomode/SKILL.md +58 -103
  142. package/skills/omc-setup/SKILL.md +197 -20
  143. package/skills/plan/SKILL.md +62 -0
  144. package/skills/project-session-manager/SKILL.md +87 -4
  145. package/skills/project-session-manager/lib/config.sh +54 -5
  146. package/skills/project-session-manager/lib/parse.sh +65 -11
  147. package/skills/project-session-manager/lib/providers/github.sh +52 -0
  148. package/skills/project-session-manager/lib/providers/interface.sh +76 -0
  149. package/skills/project-session-manager/lib/providers/jira.sh +79 -0
  150. package/skills/project-session-manager/lib/session.sh +49 -12
  151. package/skills/project-session-manager/lib/worktree.sh +37 -4
  152. package/skills/project-session-manager/psm.sh +116 -51
  153. package/skills/ralph/SKILL.md +41 -27
  154. package/skills/ultrawork/SKILL.md +56 -66
  155. package/templates/hooks/keyword-detector.mjs +21 -13
  156. package/templates/hooks/lib/stdin.mjs +62 -0
  157. package/templates/hooks/persistent-mode.mjs +7 -8
  158. package/templates/hooks/post-tool-use.mjs +8 -10
  159. package/templates/hooks/pre-tool-use.mjs +9 -6
  160. package/templates/hooks/session-start.mjs +7 -8
@@ -0,0 +1,62 @@
1
+ /**
2
+ * Shared stdin utilities for OMC hooks
3
+ * Provides timeout-protected stdin reading to prevent hangs on Linux
4
+ * See: https://github.com/Yeachan-Heo/oh-my-claudecode/issues/240
5
+ */
6
+
7
+ /**
8
+ * Read all stdin with timeout to prevent indefinite hang on Linux.
9
+ *
10
+ * The blocking `for await (const chunk of process.stdin)` pattern waits
11
+ * indefinitely for EOF. On Linux, if the parent process doesn't properly
12
+ * close stdin, this hangs forever. This function uses event-based reading
13
+ * with a timeout as a safety net.
14
+ *
15
+ * @param {number} timeoutMs - Maximum time to wait for stdin (default: 5000ms)
16
+ * @returns {Promise<string>} - The stdin content, or empty string on error/timeout
17
+ */
18
+ export async function readStdin(timeoutMs = 5000) {
19
+ return new Promise((resolve) => {
20
+ const chunks = [];
21
+ let settled = false;
22
+
23
+ const timeout = setTimeout(() => {
24
+ if (!settled) {
25
+ settled = true;
26
+ process.stdin.removeAllListeners();
27
+ process.stdin.destroy();
28
+ resolve(Buffer.concat(chunks).toString('utf-8'));
29
+ }
30
+ }, timeoutMs);
31
+
32
+ process.stdin.on('data', (chunk) => {
33
+ chunks.push(chunk);
34
+ });
35
+
36
+ process.stdin.on('end', () => {
37
+ if (!settled) {
38
+ settled = true;
39
+ clearTimeout(timeout);
40
+ resolve(Buffer.concat(chunks).toString('utf-8'));
41
+ }
42
+ });
43
+
44
+ process.stdin.on('error', () => {
45
+ if (!settled) {
46
+ settled = true;
47
+ clearTimeout(timeout);
48
+ resolve('');
49
+ }
50
+ });
51
+
52
+ // If stdin is already ended (e.g. empty pipe), 'end' fires immediately
53
+ // But if stdin is a TTY or never piped, we need the timeout as safety net
54
+ if (process.stdin.readableEnded) {
55
+ if (!settled) {
56
+ settled = true;
57
+ clearTimeout(timeout);
58
+ resolve(Buffer.concat(chunks).toString('utf-8'));
59
+ }
60
+ }
61
+ });
62
+ }
@@ -9,16 +9,15 @@
9
9
  */
10
10
 
11
11
  import { existsSync, readFileSync, writeFileSync, readdirSync, mkdirSync } from 'fs';
12
- import { join } from 'path';
12
+ import { join, dirname } from 'path';
13
13
  import { homedir } from 'os';
14
+ import { fileURLToPath } from 'url';
14
15
 
15
- async function readStdin() {
16
- const chunks = [];
17
- for await (const chunk of process.stdin) {
18
- chunks.push(chunk);
19
- }
20
- return Buffer.concat(chunks).toString('utf-8');
21
- }
16
+ const __filename = fileURLToPath(import.meta.url);
17
+ const __dirname = dirname(__filename);
18
+
19
+ // Dynamic import for the shared stdin module
20
+ const { readStdin } = await import(join(__dirname, 'lib', 'stdin.mjs'));
22
21
 
23
22
  function readJsonFile(path) {
24
23
  try {
@@ -4,7 +4,14 @@
4
4
  // Saves to .omc/notepad.md for compaction-resilient memory
5
5
 
6
6
  import { existsSync, readFileSync, writeFileSync, mkdirSync } from 'fs';
7
- import { join } from 'path';
7
+ import { join, dirname } from 'path';
8
+ import { fileURLToPath } from 'url';
9
+
10
+ const __filename = fileURLToPath(import.meta.url);
11
+ const __dirname = dirname(__filename);
12
+
13
+ // Dynamic import for the shared stdin module
14
+ const { readStdin } = await import(join(__dirname, 'lib', 'stdin.mjs'));
8
15
 
9
16
  // Constants
10
17
  const NOTEPAD_TEMPLATE = '# Notepad\n' +
@@ -16,15 +23,6 @@ const NOTEPAD_TEMPLATE = '# Notepad\n' +
16
23
  '## MANUAL\n' +
17
24
  '<!-- User content. Never auto-pruned. -->\n';
18
25
 
19
- // Read all stdin
20
- async function readStdin() {
21
- const chunks = [];
22
- for await (const chunk of process.stdin) {
23
- chunks.push(chunk);
24
- }
25
- return Buffer.concat(chunks).toString('utf-8');
26
- }
27
-
28
26
  // Initialize notepad.md if needed
29
27
  function initNotepad(directory) {
30
28
  const sisyphusDir = join(directory, '.omc');
@@ -5,6 +5,14 @@
5
5
  */
6
6
 
7
7
  import * as path from 'path';
8
+ import { dirname } from 'path';
9
+ import { fileURLToPath } from 'url';
10
+
11
+ const __filename = fileURLToPath(import.meta.url);
12
+ const __dirname = dirname(__filename);
13
+
14
+ // Dynamic import for the shared stdin module
15
+ const { readStdin } = await import(path.join(__dirname, 'lib', 'stdin.mjs'));
8
16
 
9
17
  // Allowed path patterns (no warning)
10
18
  const ALLOWED_PATH_PATTERNS = [
@@ -70,12 +78,7 @@ This is a soft warning. Operation will proceed.`;
70
78
  }
71
79
 
72
80
  async function main() {
73
- let input = '';
74
-
75
- // Read stdin
76
- for await (const chunk of process.stdin) {
77
- input += chunk;
78
- }
81
+ const input = await readStdin();
79
82
 
80
83
  let data;
81
84
  try {
@@ -4,16 +4,15 @@
4
4
  // Cross-platform: Windows, macOS, Linux
5
5
 
6
6
  import { existsSync, readFileSync, readdirSync, writeFileSync, mkdirSync } from 'fs';
7
- import { join } from 'path';
7
+ import { join, dirname } from 'path';
8
8
  import { homedir } from 'os';
9
+ import { fileURLToPath } from 'url';
9
10
 
10
- async function readStdin() {
11
- const chunks = [];
12
- for await (const chunk of process.stdin) {
13
- chunks.push(chunk);
14
- }
15
- return Buffer.concat(chunks).toString('utf-8');
16
- }
11
+ const __filename = fileURLToPath(import.meta.url);
12
+ const __dirname = dirname(__filename);
13
+
14
+ // Dynamic import for the shared stdin module
15
+ const { readStdin } = await import(join(__dirname, 'lib', 'stdin.mjs'));
17
16
 
18
17
  function readJsonFile(path) {
19
18
  try {