hammoc 1.3.0 → 1.5.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 (336) hide show
  1. package/README.md +422 -403
  2. package/bin/hammoc.js +0 -6
  3. package/package.json +100 -93
  4. package/packages/client/dist/assets/agentExampleHighlight-BgwTm15v.js +1 -0
  5. package/packages/client/dist/assets/commandTokenHighlight-BljHwnrK.js +1 -0
  6. package/packages/client/dist/assets/index-CjyjnXB8.css +32 -0
  7. package/packages/client/dist/assets/index-D3LxqW3f.js +2 -0
  8. package/packages/client/dist/assets/index-NqJdhlek.js +1498 -0
  9. package/packages/client/dist/assets/snippetTokenHighlight-DWsaQXX0.js +1 -0
  10. package/packages/client/dist/index.html +2 -2
  11. package/packages/client/dist/sw.js +1 -1
  12. package/packages/server/dist/app.d.ts.map +1 -1
  13. package/packages/server/dist/app.js +24 -24
  14. package/packages/server/dist/app.js.map +1 -1
  15. package/packages/server/dist/controllers/boardController.d.ts.map +1 -1
  16. package/packages/server/dist/controllers/boardController.js +0 -5
  17. package/packages/server/dist/controllers/boardController.js.map +1 -1
  18. package/packages/server/dist/controllers/claudeMdController.d.ts +26 -0
  19. package/packages/server/dist/controllers/claudeMdController.d.ts.map +1 -0
  20. package/packages/server/dist/controllers/claudeMdController.js +158 -0
  21. package/packages/server/dist/controllers/claudeMdController.js.map +1 -0
  22. package/packages/server/dist/controllers/fileSystemController.d.ts +4 -0
  23. package/packages/server/dist/controllers/fileSystemController.d.ts.map +1 -1
  24. package/packages/server/dist/controllers/fileSystemController.js +20 -2
  25. package/packages/server/dist/controllers/fileSystemController.js.map +1 -1
  26. package/packages/server/dist/controllers/harnessAgentController.d.ts +28 -0
  27. package/packages/server/dist/controllers/harnessAgentController.d.ts.map +1 -0
  28. package/packages/server/dist/controllers/harnessAgentController.js +339 -0
  29. package/packages/server/dist/controllers/harnessAgentController.js.map +1 -0
  30. package/packages/server/dist/controllers/harnessCommandController.d.ts +28 -0
  31. package/packages/server/dist/controllers/harnessCommandController.d.ts.map +1 -0
  32. package/packages/server/dist/controllers/harnessCommandController.js +382 -0
  33. package/packages/server/dist/controllers/harnessCommandController.js.map +1 -0
  34. package/packages/server/dist/controllers/harnessController.d.ts +21 -0
  35. package/packages/server/dist/controllers/harnessController.d.ts.map +1 -0
  36. package/packages/server/dist/controllers/harnessController.js +176 -0
  37. package/packages/server/dist/controllers/harnessController.js.map +1 -0
  38. package/packages/server/dist/controllers/harnessHookController.d.ts +32 -0
  39. package/packages/server/dist/controllers/harnessHookController.d.ts.map +1 -0
  40. package/packages/server/dist/controllers/harnessHookController.js +363 -0
  41. package/packages/server/dist/controllers/harnessHookController.js.map +1 -0
  42. package/packages/server/dist/controllers/harnessLintController.d.ts +18 -0
  43. package/packages/server/dist/controllers/harnessLintController.d.ts.map +1 -0
  44. package/packages/server/dist/controllers/harnessLintController.js +72 -0
  45. package/packages/server/dist/controllers/harnessLintController.js.map +1 -0
  46. package/packages/server/dist/controllers/harnessMcpController.d.ts +28 -0
  47. package/packages/server/dist/controllers/harnessMcpController.d.ts.map +1 -0
  48. package/packages/server/dist/controllers/harnessMcpController.js +310 -0
  49. package/packages/server/dist/controllers/harnessMcpController.js.map +1 -0
  50. package/packages/server/dist/controllers/harnessPluginController.d.ts +17 -0
  51. package/packages/server/dist/controllers/harnessPluginController.d.ts.map +1 -0
  52. package/packages/server/dist/controllers/harnessPluginController.js +115 -0
  53. package/packages/server/dist/controllers/harnessPluginController.js.map +1 -0
  54. package/packages/server/dist/controllers/harnessShareScopeController.d.ts +15 -0
  55. package/packages/server/dist/controllers/harnessShareScopeController.d.ts.map +1 -0
  56. package/packages/server/dist/controllers/harnessShareScopeController.js +73 -0
  57. package/packages/server/dist/controllers/harnessShareScopeController.js.map +1 -0
  58. package/packages/server/dist/controllers/harnessSkillController.d.ts +32 -0
  59. package/packages/server/dist/controllers/harnessSkillController.d.ts.map +1 -0
  60. package/packages/server/dist/controllers/harnessSkillController.js +453 -0
  61. package/packages/server/dist/controllers/harnessSkillController.js.map +1 -0
  62. package/packages/server/dist/controllers/projectController.d.ts.map +1 -1
  63. package/packages/server/dist/controllers/projectController.js +11 -0
  64. package/packages/server/dist/controllers/projectController.js.map +1 -1
  65. package/packages/server/dist/controllers/serverController.d.ts.map +1 -1
  66. package/packages/server/dist/controllers/serverController.js +84 -49
  67. package/packages/server/dist/controllers/serverController.js.map +1 -1
  68. package/packages/server/dist/controllers/snippetController.d.ts +35 -0
  69. package/packages/server/dist/controllers/snippetController.d.ts.map +1 -0
  70. package/packages/server/dist/controllers/snippetController.js +294 -0
  71. package/packages/server/dist/controllers/snippetController.js.map +1 -0
  72. package/packages/server/dist/handlers/websocket.d.ts +16 -0
  73. package/packages/server/dist/handlers/websocket.d.ts.map +1 -1
  74. package/packages/server/dist/handlers/websocket.js +221 -8
  75. package/packages/server/dist/handlers/websocket.js.map +1 -1
  76. package/packages/server/dist/index.js +66 -0
  77. package/packages/server/dist/index.js.map +1 -1
  78. package/packages/server/dist/locales/en/server.json +41 -6
  79. package/packages/server/dist/locales/es/server.json +3 -5
  80. package/packages/server/dist/locales/ja/server.json +3 -5
  81. package/packages/server/dist/locales/ko/server.json +4 -6
  82. package/packages/server/dist/locales/pt/server.json +3 -5
  83. package/packages/server/dist/locales/zh-CN/server.json +3 -5
  84. package/packages/server/dist/routes/account.d.ts +7 -0
  85. package/packages/server/dist/routes/account.d.ts.map +1 -0
  86. package/packages/server/dist/routes/account.js +35 -0
  87. package/packages/server/dist/routes/account.js.map +1 -0
  88. package/packages/server/dist/routes/debug.d.ts +1 -1
  89. package/packages/server/dist/routes/debug.d.ts.map +1 -1
  90. package/packages/server/dist/routes/debug.js +60 -1
  91. package/packages/server/dist/routes/debug.js.map +1 -1
  92. package/packages/server/dist/routes/harness.d.ts +8 -0
  93. package/packages/server/dist/routes/harness.d.ts.map +1 -0
  94. package/packages/server/dist/routes/harness.js +92 -0
  95. package/packages/server/dist/routes/harness.js.map +1 -0
  96. package/packages/server/dist/routes/preferences.d.ts.map +1 -1
  97. package/packages/server/dist/routes/preferences.js +11 -2
  98. package/packages/server/dist/routes/preferences.js.map +1 -1
  99. package/packages/server/dist/routes/projects.d.ts.map +1 -1
  100. package/packages/server/dist/routes/projects.js +5 -60
  101. package/packages/server/dist/routes/projects.js.map +1 -1
  102. package/packages/server/dist/routes/snippets.d.ts +14 -0
  103. package/packages/server/dist/routes/snippets.d.ts.map +1 -0
  104. package/packages/server/dist/routes/snippets.js +27 -0
  105. package/packages/server/dist/routes/snippets.js.map +1 -0
  106. package/packages/server/dist/services/accountInfoService.d.ts +38 -0
  107. package/packages/server/dist/services/accountInfoService.d.ts.map +1 -0
  108. package/packages/server/dist/services/accountInfoService.js +118 -0
  109. package/packages/server/dist/services/accountInfoService.js.map +1 -0
  110. package/packages/server/dist/services/bmadStatusService.d.ts +6 -2
  111. package/packages/server/dist/services/bmadStatusService.d.ts.map +1 -1
  112. package/packages/server/dist/services/bmadStatusService.js +88 -32
  113. package/packages/server/dist/services/bmadStatusService.js.map +1 -1
  114. package/packages/server/dist/services/chatService.d.ts +3 -0
  115. package/packages/server/dist/services/chatService.d.ts.map +1 -1
  116. package/packages/server/dist/services/chatService.js +36 -8
  117. package/packages/server/dist/services/chatService.js.map +1 -1
  118. package/packages/server/dist/services/claudeMdService.d.ts +48 -0
  119. package/packages/server/dist/services/claudeMdService.d.ts.map +1 -0
  120. package/packages/server/dist/services/claudeMdService.js +240 -0
  121. package/packages/server/dist/services/claudeMdService.js.map +1 -0
  122. package/packages/server/dist/services/commandService.d.ts +10 -0
  123. package/packages/server/dist/services/commandService.d.ts.map +1 -1
  124. package/packages/server/dist/services/commandService.js +129 -4
  125. package/packages/server/dist/services/commandService.js.map +1 -1
  126. package/packages/server/dist/services/fileSystemService.d.ts +7 -1
  127. package/packages/server/dist/services/fileSystemService.d.ts.map +1 -1
  128. package/packages/server/dist/services/fileSystemService.js +67 -8
  129. package/packages/server/dist/services/fileSystemService.js.map +1 -1
  130. package/packages/server/dist/services/fileWatcherService.d.ts +59 -0
  131. package/packages/server/dist/services/fileWatcherService.d.ts.map +1 -0
  132. package/packages/server/dist/services/fileWatcherService.js +329 -0
  133. package/packages/server/dist/services/fileWatcherService.js.map +1 -0
  134. package/packages/server/dist/services/gitService.d.ts.map +1 -1
  135. package/packages/server/dist/services/gitService.js +67 -7
  136. package/packages/server/dist/services/gitService.js.map +1 -1
  137. package/packages/server/dist/services/harnessAgentService.d.ts +79 -0
  138. package/packages/server/dist/services/harnessAgentService.d.ts.map +1 -0
  139. package/packages/server/dist/services/harnessAgentService.js +933 -0
  140. package/packages/server/dist/services/harnessAgentService.js.map +1 -0
  141. package/packages/server/dist/services/harnessCommandService.d.ts +60 -0
  142. package/packages/server/dist/services/harnessCommandService.d.ts.map +1 -0
  143. package/packages/server/dist/services/harnessCommandService.js +853 -0
  144. package/packages/server/dist/services/harnessCommandService.js.map +1 -0
  145. package/packages/server/dist/services/harnessHookService.d.ts +55 -0
  146. package/packages/server/dist/services/harnessHookService.d.ts.map +1 -0
  147. package/packages/server/dist/services/harnessHookService.js +1060 -0
  148. package/packages/server/dist/services/harnessHookService.js.map +1 -0
  149. package/packages/server/dist/services/harnessLintService.d.ts +49 -0
  150. package/packages/server/dist/services/harnessLintService.d.ts.map +1 -0
  151. package/packages/server/dist/services/harnessLintService.js +628 -0
  152. package/packages/server/dist/services/harnessLintService.js.map +1 -0
  153. package/packages/server/dist/services/harnessMcpService.d.ts +77 -0
  154. package/packages/server/dist/services/harnessMcpService.d.ts.map +1 -0
  155. package/packages/server/dist/services/harnessMcpService.js +814 -0
  156. package/packages/server/dist/services/harnessMcpService.js.map +1 -0
  157. package/packages/server/dist/services/harnessPluginService.d.ts +66 -0
  158. package/packages/server/dist/services/harnessPluginService.d.ts.map +1 -0
  159. package/packages/server/dist/services/harnessPluginService.js +559 -0
  160. package/packages/server/dist/services/harnessPluginService.js.map +1 -0
  161. package/packages/server/dist/services/harnessService.d.ts +40 -0
  162. package/packages/server/dist/services/harnessService.d.ts.map +1 -0
  163. package/packages/server/dist/services/harnessService.js +222 -0
  164. package/packages/server/dist/services/harnessService.js.map +1 -0
  165. package/packages/server/dist/services/harnessShareScopeService.d.ts +31 -0
  166. package/packages/server/dist/services/harnessShareScopeService.d.ts.map +1 -0
  167. package/packages/server/dist/services/harnessShareScopeService.js +93 -0
  168. package/packages/server/dist/services/harnessShareScopeService.js.map +1 -0
  169. package/packages/server/dist/services/harnessSkillService.d.ts +70 -0
  170. package/packages/server/dist/services/harnessSkillService.d.ts.map +1 -0
  171. package/packages/server/dist/services/harnessSkillService.js +636 -0
  172. package/packages/server/dist/services/harnessSkillService.js.map +1 -0
  173. package/packages/server/dist/services/historyParser.d.ts +4 -14
  174. package/packages/server/dist/services/historyParser.d.ts.map +1 -1
  175. package/packages/server/dist/services/historyParser.js +60 -5
  176. package/packages/server/dist/services/historyParser.js.map +1 -1
  177. package/packages/server/dist/services/issueService.d.ts.map +1 -1
  178. package/packages/server/dist/services/issueService.js +10 -2
  179. package/packages/server/dist/services/issueService.js.map +1 -1
  180. package/packages/server/dist/services/manualSyncService.d.ts +19 -0
  181. package/packages/server/dist/services/manualSyncService.d.ts.map +1 -0
  182. package/packages/server/dist/services/manualSyncService.js +110 -0
  183. package/packages/server/dist/services/manualSyncService.js.map +1 -0
  184. package/packages/server/dist/services/notificationService.d.ts.map +1 -1
  185. package/packages/server/dist/services/notificationService.js +34 -9
  186. package/packages/server/dist/services/notificationService.js.map +1 -1
  187. package/packages/server/dist/services/preferencesService.d.ts.map +1 -1
  188. package/packages/server/dist/services/preferencesService.js +8 -1
  189. package/packages/server/dist/services/preferencesService.js.map +1 -1
  190. package/packages/server/dist/services/projectService.d.ts +5 -0
  191. package/packages/server/dist/services/projectService.d.ts.map +1 -1
  192. package/packages/server/dist/services/projectService.js +42 -2
  193. package/packages/server/dist/services/projectService.js.map +1 -1
  194. package/packages/server/dist/services/ptyService.d.ts +1 -0
  195. package/packages/server/dist/services/ptyService.d.ts.map +1 -1
  196. package/packages/server/dist/services/ptyService.js +36 -5
  197. package/packages/server/dist/services/ptyService.js.map +1 -1
  198. package/packages/server/dist/services/queueService.d.ts.map +1 -1
  199. package/packages/server/dist/services/queueService.js +83 -14
  200. package/packages/server/dist/services/queueService.js.map +1 -1
  201. package/packages/server/dist/services/sessionBufferManager.d.ts.map +1 -1
  202. package/packages/server/dist/services/sessionBufferManager.js +26 -0
  203. package/packages/server/dist/services/sessionBufferManager.js.map +1 -1
  204. package/packages/server/dist/services/sessionService.d.ts +4 -3
  205. package/packages/server/dist/services/sessionService.d.ts.map +1 -1
  206. package/packages/server/dist/services/sessionService.js +5 -4
  207. package/packages/server/dist/services/sessionService.js.map +1 -1
  208. package/packages/server/dist/services/snippetService.d.ts +54 -0
  209. package/packages/server/dist/services/snippetService.d.ts.map +1 -0
  210. package/packages/server/dist/services/snippetService.js +371 -0
  211. package/packages/server/dist/services/snippetService.js.map +1 -0
  212. package/packages/server/dist/services/utils/applyYamlFrontmatterPatch.d.ts +46 -0
  213. package/packages/server/dist/services/utils/applyYamlFrontmatterPatch.d.ts.map +1 -0
  214. package/packages/server/dist/services/utils/applyYamlFrontmatterPatch.js +125 -0
  215. package/packages/server/dist/services/utils/applyYamlFrontmatterPatch.js.map +1 -0
  216. package/packages/server/dist/services/webPushService.d.ts.map +1 -1
  217. package/packages/server/dist/services/webPushService.js +8 -1
  218. package/packages/server/dist/services/webPushService.js.map +1 -1
  219. package/packages/server/dist/snippets/split-commit +9 -0
  220. package/packages/server/dist/utils/applySecretsPolicy.d.ts +53 -0
  221. package/packages/server/dist/utils/applySecretsPolicy.d.ts.map +1 -0
  222. package/packages/server/dist/utils/applySecretsPolicy.js +204 -0
  223. package/packages/server/dist/utils/applySecretsPolicy.js.map +1 -0
  224. package/packages/server/dist/utils/assertNoSecretOnShared.d.ts +40 -0
  225. package/packages/server/dist/utils/assertNoSecretOnShared.d.ts.map +1 -0
  226. package/packages/server/dist/utils/assertNoSecretOnShared.js +47 -0
  227. package/packages/server/dist/utils/assertNoSecretOnShared.js.map +1 -0
  228. package/packages/server/dist/utils/effortUtils.d.ts +21 -0
  229. package/packages/server/dist/utils/effortUtils.d.ts.map +1 -0
  230. package/packages/server/dist/utils/effortUtils.js +36 -0
  231. package/packages/server/dist/utils/effortUtils.js.map +1 -0
  232. package/packages/server/dist/utils/gitignoreFilter.d.ts +23 -0
  233. package/packages/server/dist/utils/gitignoreFilter.d.ts.map +1 -0
  234. package/packages/server/dist/utils/gitignoreFilter.js +42 -0
  235. package/packages/server/dist/utils/gitignoreFilter.js.map +1 -0
  236. package/packages/server/dist/utils/harnessBundleSchema.d.ts +105 -0
  237. package/packages/server/dist/utils/harnessBundleSchema.d.ts.map +1 -0
  238. package/packages/server/dist/utils/harnessBundleSchema.js +79 -0
  239. package/packages/server/dist/utils/harnessBundleSchema.js.map +1 -0
  240. package/packages/server/dist/utils/harnessPaths.d.ts +34 -0
  241. package/packages/server/dist/utils/harnessPaths.d.ts.map +1 -0
  242. package/packages/server/dist/utils/harnessPaths.js +124 -0
  243. package/packages/server/dist/utils/harnessPaths.js.map +1 -0
  244. package/packages/server/dist/utils/pathUtils.d.ts +3 -2
  245. package/packages/server/dist/utils/pathUtils.d.ts.map +1 -1
  246. package/packages/server/dist/utils/pathUtils.js +26 -2
  247. package/packages/server/dist/utils/pathUtils.js.map +1 -1
  248. package/packages/server/dist/utils/secretHeuristic.d.ts +72 -0
  249. package/packages/server/dist/utils/secretHeuristic.d.ts.map +1 -0
  250. package/packages/server/dist/utils/secretHeuristic.js +163 -0
  251. package/packages/server/dist/utils/secretHeuristic.js.map +1 -0
  252. package/packages/server/dist/utils/secretPlaceholderNamer.d.ts +41 -0
  253. package/packages/server/dist/utils/secretPlaceholderNamer.d.ts.map +1 -0
  254. package/packages/server/dist/utils/secretPlaceholderNamer.js +81 -0
  255. package/packages/server/dist/utils/secretPlaceholderNamer.js.map +1 -0
  256. package/packages/server/dist/utils/serverPathResolver.d.ts +29 -0
  257. package/packages/server/dist/utils/serverPathResolver.d.ts.map +1 -0
  258. package/packages/server/dist/utils/serverPathResolver.js +59 -0
  259. package/packages/server/dist/utils/serverPathResolver.js.map +1 -0
  260. package/packages/server/dist/utils/snippetPaths.d.ts +61 -0
  261. package/packages/server/dist/utils/snippetPaths.d.ts.map +1 -0
  262. package/packages/server/dist/utils/snippetPaths.js +123 -0
  263. package/packages/server/dist/utils/snippetPaths.js.map +1 -0
  264. package/packages/server/dist/utils/structuredEditor.d.ts +34 -0
  265. package/packages/server/dist/utils/structuredEditor.d.ts.map +1 -0
  266. package/packages/server/dist/utils/structuredEditor.js +111 -0
  267. package/packages/server/dist/utils/structuredEditor.js.map +1 -0
  268. package/packages/server/package.json +6 -2
  269. package/packages/server/resources/internals/INDEX.md +23 -0
  270. package/packages/server/resources/internals/harness-files.md +63 -0
  271. package/packages/server/resources/internals/image-storage.md +43 -0
  272. package/packages/server/resources/manual/01-getting-started.md +104 -0
  273. package/packages/server/resources/manual/02-chat.md +285 -0
  274. package/packages/server/resources/manual/03-sessions.md +48 -0
  275. package/packages/server/resources/manual/04-slash-commands-favorites.md +152 -0
  276. package/packages/server/resources/manual/05-projects.md +74 -0
  277. package/packages/server/resources/manual/06-file-explorer-editor.md +90 -0
  278. package/packages/server/resources/manual/07-git.md +94 -0
  279. package/packages/server/resources/manual/08-terminal.md +59 -0
  280. package/packages/server/resources/manual/09-queue-runner.md +262 -0
  281. package/packages/server/resources/manual/10-project-board.md +193 -0
  282. package/packages/server/resources/manual/11-bmad-method-integration.md +128 -0
  283. package/packages/server/resources/manual/12-harness-workbench.md +175 -0
  284. package/packages/server/resources/manual/13-settings.md +241 -0
  285. package/packages/server/resources/manual/14-keyboard-shortcuts.md +68 -0
  286. package/packages/server/resources/manual/15-environment-variables.md +28 -0
  287. package/packages/server/resources/manual/16-troubleshooting.md +110 -0
  288. package/packages/server/resources/manual/INDEX.md +60 -0
  289. package/packages/shared/dist/index.d.ts +3 -0
  290. package/packages/shared/dist/index.d.ts.map +1 -1
  291. package/packages/shared/dist/index.js +6 -0
  292. package/packages/shared/dist/index.js.map +1 -1
  293. package/packages/shared/dist/types/command.d.ts +3 -3
  294. package/packages/shared/dist/types/command.d.ts.map +1 -1
  295. package/packages/shared/dist/types/fileSystem.d.ts +19 -0
  296. package/packages/shared/dist/types/fileSystem.d.ts.map +1 -1
  297. package/packages/shared/dist/types/fileSystem.js +5 -0
  298. package/packages/shared/dist/types/fileSystem.js.map +1 -1
  299. package/packages/shared/dist/types/git.d.ts +6 -1
  300. package/packages/shared/dist/types/git.d.ts.map +1 -1
  301. package/packages/shared/dist/types/git.js.map +1 -1
  302. package/packages/shared/dist/types/harness.d.ts +1211 -0
  303. package/packages/shared/dist/types/harness.d.ts.map +1 -0
  304. package/packages/shared/dist/types/harness.js +107 -0
  305. package/packages/shared/dist/types/harness.js.map +1 -0
  306. package/packages/shared/dist/types/harnessBundle.d.ts +170 -0
  307. package/packages/shared/dist/types/harnessBundle.d.ts.map +1 -0
  308. package/packages/shared/dist/types/harnessBundle.js +18 -0
  309. package/packages/shared/dist/types/harnessBundle.js.map +1 -0
  310. package/packages/shared/dist/types/history.d.ts +7 -0
  311. package/packages/shared/dist/types/history.d.ts.map +1 -1
  312. package/packages/shared/dist/types/preferences.d.ts +4 -1
  313. package/packages/shared/dist/types/preferences.d.ts.map +1 -1
  314. package/packages/shared/dist/types/preferences.js +1 -0
  315. package/packages/shared/dist/types/preferences.js.map +1 -1
  316. package/packages/shared/dist/types/queue.d.ts +9 -0
  317. package/packages/shared/dist/types/queue.d.ts.map +1 -1
  318. package/packages/shared/dist/types/sdk.d.ts +42 -1
  319. package/packages/shared/dist/types/sdk.d.ts.map +1 -1
  320. package/packages/shared/dist/types/sdk.js +26 -2
  321. package/packages/shared/dist/types/sdk.js.map +1 -1
  322. package/packages/shared/dist/types/websocket.d.ts +24 -0
  323. package/packages/shared/dist/types/websocket.d.ts.map +1 -1
  324. package/packages/shared/dist/utils/markdownSections.d.ts +50 -0
  325. package/packages/shared/dist/utils/markdownSections.d.ts.map +1 -0
  326. package/packages/shared/dist/utils/markdownSections.js +111 -0
  327. package/packages/shared/dist/utils/markdownSections.js.map +1 -0
  328. package/packages/shared/dist/utils/queueParser.d.ts.map +1 -1
  329. package/packages/shared/dist/utils/queueParser.js +104 -0
  330. package/packages/shared/dist/utils/queueParser.js.map +1 -1
  331. package/scripts/build-manual-shards.mjs +100 -0
  332. package/scripts/mock-telegram.mjs +172 -0
  333. package/scripts/run-integration-test.mjs +362 -0
  334. package/packages/client/dist/assets/index-Bf0D9oVJ.css +0 -32
  335. package/packages/client/dist/assets/index-CRmzoqHy.js +0 -2
  336. package/packages/client/dist/assets/index-CszGQ29O.js +0 -1432
package/README.md CHANGED
@@ -1,403 +1,422 @@
1
- <p align="center">
2
- <img src="logo/Hammoc-Header.png" alt="Hammoc" width="480">
3
- </p>
4
-
5
- <p align="center">
6
- <strong>Kick Back. Tap. Ship.</strong><br>
7
- The web IDE built for AI-driven development workflows — starting with BMAD-METHOD.
8
- </p>
9
-
10
- <p align="center">
11
- <a href="https://www.npmjs.com/package/hammoc"><img src="https://img.shields.io/npm/v/hammoc" alt="npm version"></a>
12
- <a href="https://www.npmjs.com/package/hammoc"><img src="https://img.shields.io/npm/dm/hammoc" alt="npm downloads"></a>
13
- <a href="LICENSE"><img src="https://img.shields.io/github/license/starsh2001/hammoc" alt="license"></a>
14
- </p>
15
-
16
- <p align="center">
17
- <a href="docs/MANUAL.md"><strong>User Manual</strong></a> ·
18
- <a href="#quick-start"><strong>Quick Start</strong></a> ·
19
- <a href="#features"><strong>Features</strong></a>
20
- </p>
21
-
22
- ---
23
-
24
- ## What is Hammoc?
25
-
26
- Hammoc is a web IDE optimized for structured AI-driven development methodologies. It currently provides first-class support for the [BMAD-METHOD V4](https://github.com/bmad-code-org/BMAD-METHOD) workflow — with plans to support additional methodologies in the future.
27
-
28
- Built on top of [Claude Code](https://docs.anthropic.com/en/docs/claude-code), Hammoc provides everything you need to run a full BMAD workflow from your browser: agent switching, PRD-to-queue automation, epic/story tracking, and a Kanban board — all in one place. No terminal hopping, no context switching.
29
-
30
- Fully responsive and mobile-first. Kick back in your hammock, tap a command on your phone, and let the AI ship it. Inspired by Rich Hickey's *Hammock Driven Development* — the idea that real breakthroughs come when you step back, not when you're grinding at the terminal.
31
-
32
- ---
33
-
34
- ## Quick Start
35
-
36
- ### Prerequisites
37
-
38
- - **Node.js** >= 18.0.0 (v22 LTS recommended)
39
- - **Claude Code CLI** installed and authenticated (`claude --version`)
40
-
41
- ### Install & Run
42
-
43
- ```bash
44
- # Run directly (no install needed)
45
- npx hammoc
46
-
47
- # Or install globally
48
- npm install -g hammoc
49
- hammoc
50
- ```
51
-
52
- Open http://localhost:3000 in your browser. First launch guides you through password setup and CLI verification.
53
-
54
- ### CLI Options
55
-
56
- ```
57
- hammoc [options]
58
-
59
- Options:
60
- --port <number> Port to listen on (default: 3000, env: PORT)
61
- --host <string> Host to bind to (default: 0.0.0.0, env: HOST)
62
- --trust-proxy Enable reverse proxy support (env: TRUST_PROXY)
63
- --cors-origin <url> Restrict CORS to specific origin (env: CORS_ORIGIN)
64
- --rate-limit <number> Requests per minute per IP (default: 200, env: RATE_LIMIT)
65
- --reset-password Reset the admin password
66
- -h, --help Show this help message
67
- -v, --version Show version number
68
- ```
69
-
70
- ### Mobile Access
71
-
72
- Fully responsive. Access from your phone or tablet at `http://<your-ip>:3000` on the same network.
73
-
74
- ### PWA (Progressive Web App)
75
-
76
- Hammoc can be installed as a standalone app on your PC or mobile device.
77
-
78
- - **PC (localhost):** Open `http://localhost:3000` in Chrome → click the install icon in the address bar. No extra setup needed.
79
- - **Mobile (local network):** Requires HTTPS. See the [HTTPS Setup](#https-setup-for-mobile-pwa) section below.
80
-
81
- > ⚠️ **Security Notice**
82
- >
83
- > Hammoc is designed for **local network / VPN use**. While it includes security hardening for external exposure (see [Remote Access](#remote-access) below), it has not undergone a formal security audit. For maximum safety, run behind a **trusted VPN** (e.g., Tailscale, WireGuard).
84
-
85
- ### Remote Access
86
-
87
- If you need to expose Hammoc through a reverse proxy (Cloudflare Tunnel, nginx, etc.):
88
-
89
- ```bash
90
- npx hammoc --trust-proxy --cors-origin https://hammoc.yourdomain.com
91
- ```
92
-
93
- This enables:
94
- - **Proxy header support** — Correctly identifies client IPs behind the proxy (CF-Connecting-IP, X-Forwarded-For, X-Real-IP)
95
- - **Secure cookies** — Session cookies are set with `Secure` flag for HTTPS
96
- - **CORS restriction** — Only the specified origin can make authenticated requests
97
- - **Rate limiting** 200 requests/min per IP (adjust with `--rate-limit`)
98
-
99
- **Security features (always active):**
100
- - Helmet.js security headers (CSP, X-Frame-Options, HSTS, X-Content-Type-Options)
101
- - Server management APIs restricted to loopback only (127.0.0.1)
102
- - Terminal access restricted to local network IPs
103
- - IP validation with strict format checking and `net.isIP()` verification
104
- - XFF spoofing protection (rightmost IP parsing)
105
- - Debug endpoints disabled in production
106
-
107
- ---
108
-
109
- ## Features
110
-
111
- ### Why Hammoc?
112
-
113
- | | Hammoc | Terminal-based IDE | Generic Web IDE |
114
- |---|:---:|:---:|:---:|
115
- | BMAD-METHOD workflow | **Built-in** | Manual | N/A |
116
- | Agent switching (SM, PM, Dev, QA...) | **One tap** | CLI commands | N/A |
117
- | PRD Queue automation | **Auto-generate** | Copy-paste | N/A |
118
- | Mobile development | **Full support** | Limited | Partial |
119
- | Kanban + Epic tracking | **Integrated** | Separate tool | Separate tool |
120
-
121
- ### Chat Interface
122
-
123
- Real-time conversations with Claude through a rich web UI.
124
-
125
- - **Streaming responses** — Messages appear progressively as Claude generates them
126
- - **Markdown rendering** — Full markdown support with syntax-highlighted code blocks, copy buttons, and inline HTML rendering
127
- - **Image attachments** — Attach up to 5 images (PNG, JPEG, GIF, WebP) per message with thumbnail display
128
- - **Tool call visualization** — See what tools Claude uses, with inputs, outputs, and execution time
129
- - **Diff viewer** — Side-by-side file diff display for code changes
130
- - **Extended thinking** — View Claude's reasoning process in collapsible blocks
131
- - **Message edit** — Edit previous messages to branch the conversation into alternative paths
132
- - **Summarize & Continue** — Compress long conversations with AI-generated summaries
133
- - **Code rewind** — Restore project files to any earlier point in the conversation
134
- - **Session fork** — Branch into a new session from any assistant response
135
- - **Conversation branching** — Navigate between branches with pagination controls, and browse all branches in a read-only viewer
136
- - **Prompt history** — Navigate previous inputs with arrow keys
137
- - **Prompt chaining** — Queue up to 10 prompts for sequential execution (server-synced, multi-browser)
138
- - **Voice input** — Dictate messages using browser speech recognition (Chrome, Edge, Safari)
139
- - **Context usage monitor** — Track token usage and cost in real-time, with auto-compact on context overflow
140
- - **Abort generation** — Stop responses with the abort button or ESC key
141
-
142
- ### Session Management
143
-
144
- - **Session list** — Browse past conversations with preview, message count, and date
145
- - **Session search** — Search by name or conversation content (server-side)
146
- - **Session renaming & deletion** — Keep conversations organized
147
- - **Quick session panel** — Access sessions without leaving the chat
148
- - **Active streaming indicator** — See which sessions are currently active
149
-
150
- ### Slash Commands, Snippets & Favorites
151
-
152
- - **Command palette** — Type `/` to browse available commands with autocomplete
153
- - **Prompt snippets** — Type `%` to insert reusable prompt templates with argument substitution, context blocks, and multi-prompt chaining
154
- - **Snippet hierarchy** — Project, global, and bundled snippets with override support
155
- - **Favorites bar** — Pin up to 20 frequently used commands above the input
156
- - **Star favorites** — Mark up to 10 star commands for quick access
157
- - **Drag-to-reorder** — Customize favorite command order
158
- - **Agent-specific commands** — Context-aware commands per BMad agent
159
-
160
- ### Model & Permission Control
161
-
162
- - **Model selector** — Choose between Claude Sonnet, Opus, and Haiku variants with model name displayed on the button
163
- - **Thinking effort** — Adjust reasoning intensity (Low / Medium / High / Max on Opus 4.6)
164
- - **Permission modes** — Plan, Ask (default), Auto, or Bypass
165
- - **Per-project overrides** — Different settings per project
166
-
167
- ### Project Management
168
-
169
- - **Project list** — Browse all projects with session counts and last activity
170
- - **Project dashboard** — Real-time status: active chats, queue runners, terminals
171
- - **Project creation** — Create new projects with optional BMad Method initialization
172
- - **Project settings** — Per-project model, permission, system prompt, and budget configuration
173
- - **Hide/unhide projects** — Keep the list clean
174
-
175
- ### File Explorer & Editor
176
-
177
- - **Grid & List views** — Finder-style grid or traditional list layout
178
- - **Tree navigation**Directory hierarchy with breadcrumbs
179
- - **Text editor** — Syntax highlighting with save (Ctrl+S) and binary file download
180
- - **Markdown preview** — Toggle between edit and preview modes
181
- - **Image viewer** — Full-screen image viewing with zoom controls and multi-image navigation
182
- - **File operations** — Create, rename, and delete files and folders
183
-
184
- ### Git Integration
185
-
186
- - **Status panel** — Staged, unstaged, and untracked changes at a glance
187
- - **Stage & commit** — Stage files individually or all at once, write commit messages
188
- - **Branch management** Create, switch, and view branches
189
- - **Pull & Push** — Sync with remote repositories
190
- - **Quick Git panel** — Lightweight Git access from the chat view
191
-
192
- ### Terminal
193
-
194
- - **PTY emulation** — Full terminal emulation powered by xterm.js
195
- - **Multiple tabs** — Run several terminal sessions simultaneously
196
- - **Security** — Restricted to local network by default; configurable via settings
197
-
198
- ### Queue Runner (Batch Automation)
199
-
200
- Automate repetitive prompt sequences.
201
-
202
- - **Queue editor** — Write prompt sequences line by line
203
- - **Special commands** — `@new`, `@save`, `@load`, `@pause`, `@model`, `@delay`, `@pauseword`, `@loop`/`@end`, `@(/@)`, `#` comments
204
- - **Execution control** — Start, pause (deferred), resume, abort, and edit remaining items while paused
205
- - **Templates** — Save and load reusable queue scripts
206
- - **Story-based generation** — Auto-generate queue from PRD epics and stories
207
- - **Variable substitution** — Use `{story_num}`, `{epic_num}`, `{story_index}`, `{story_title}`, `{date}` in templates
208
-
209
- ### Project Board (Issue Tracking)
210
-
211
- - **Kanban board** — Visual cards across customizable status columns
212
- - **List view** — Tabular alternative with sorting and filtering
213
- - **Issue types** Bug, Improvement
214
- - **Severity levels** — Low, Medium, High, Critical
215
- - **Status workflow** — Open → Draft → Approved → In Progress → Blocked → Review → Done → Closed
216
- - **Mobile Kanban** — Touch-optimized board for small screens
217
-
218
- ### Settings
219
-
220
- - **Theme** — Dark, Light, or System
221
- - **Language** — English, 中文, 日本語, 한국어, Español, Português
222
- - **Chat timeout** — 1m, 3m, 5m (default), 10m, 30m
223
- - **Web Push & Telegram notifications** — Get notified on permission requests, completions, and errors
224
- - **System prompt editing** — Customize Claude's behavior per project
225
- - **Advanced** — Server restart, software updates, SDK parameters (thinking tokens, turns, budget)
226
-
227
- ---
228
-
229
- ## BMAD-METHOD V4 Integration
230
-
231
- Hammoc is the most convenient way to run a full [BMAD-METHOD](https://github.com/bmad-code-org/BMAD-METHOD) (Breakthrough Method for Agile AI-Driven Development) workflow. Every step — from project inception to QA — is built into the IDE.
232
-
233
- - **One-click BMad setup** — Initialize `.bmad-core` in any project with version selection
234
- - **BMad Agent switching** — Instantly switch between agents (SM, PM, Architect, Dev, QA, PO, etc.) in chat with a single tap
235
- - **Slash commands per agent** — Context-aware `/commands` that change based on the active BMad agent
236
- - **PRD → Queue automation** — Auto-generate prompt queues directly from your PRD epics and stories
237
- - **Project overview dashboard** — Visual status showing PRD completion, epic progress, and story status
238
- - **Kanban board integration** — Track epics and stories with status workflow, promote/validate actions
239
- - **Story workflows** — Start development, request QA, and apply fixes all through the board UI
240
-
241
- > **Methodology support roadmap:** Hammoc is designed to be methodology-agnostic. BMAD-METHOD V4 is the first supported workflow, with more development methodologies planned for future releases.
242
-
243
- For detailed BMAD-METHOD documentation, visit the [official repository](https://github.com/bmad-code-org/BMAD-METHOD).
244
-
245
- ---
246
-
247
- ## Keyboard Shortcuts
248
-
249
- | Shortcut | Action |
250
- |----------|--------|
251
- | `Enter` | Send message (desktop) |
252
- | `Shift+Enter` | New line in message |
253
- | `ESC` | Abort generation |
254
- | `Ctrl+S` | Save file in editor |
255
- | `Ctrl+=` `Ctrl+-` | Terminal font size |
256
- | `Ctrl+0` | Reset terminal font size |
257
- | `%` | Open snippet autocomplete palette |
258
- | `↑` / `↓` | Navigate prompt history |
259
- | `Alt+1/2/3/4` | Toggle quick panel (Sessions/Files/Git/Terminal) |
260
-
261
- ---
262
-
263
- ## Architecture
264
-
265
- Hammoc is a monorepo with three packages:
266
-
267
- ```
268
- hammoc/
269
- ├── bin/hammoc.js # CLI entry point
270
- ├── packages/
271
- │ ├── shared/ # Shared types, constants, utilities
272
- │ ├── server/ # Express + Socket.io backend
273
- │ └── client/ # React + Vite frontend
274
- └── scripts/
275
- └── postinstall.cjs # Shared package linker
276
- ```
277
-
278
- **Tech Stack:**
279
- - **Frontend:** React 18, Vite, Tailwind CSS, Zustand, Socket.io Client, xterm.js
280
- - **Backend:** Node.js, Express, Socket.io, node-pty, Claude Agent SDK
281
- - **Shared:** TypeScript, Zod validation
282
-
283
- ---
284
-
285
- ## Development
286
-
287
- ```bash
288
- git clone https://github.com/starsh2001/hammoc.git
289
- cd hammoc
290
- npm install
291
- npm run dev
292
- ```
293
-
294
- | Command | Description |
295
- |---------|-------------|
296
- | `npm run dev` | Start all packages in development mode |
297
- | `npm run build` | Build all packages for production |
298
- | `npm start` | Run server in production mode |
299
- | `npm test` | Run all tests |
300
- | `npm run lint` | Run ESLint on all packages |
301
- | `npm run typecheck` | Run TypeScript type checking |
302
-
303
- ---
304
-
305
- ## Data Storage
306
-
307
- | Data | Location |
308
- |------|----------|
309
- | App config & password | `~/.hammoc/config.json` |
310
- | User preferences | `~/.hammoc/preferences.json` |
311
- | Queue templates | `<project-root>/.hammoc/queue-templates.json` (per project) |
312
- | Chain failures | `~/.hammoc/chain-failures/<sessionId>.json` (per session) |
313
- | Snippets (global) | `~/.hammoc/snippets/` (shared across projects) |
314
- | Snippets (project) | `<project-root>/.hammoc/snippets/` (per project) |
315
- | TLS certificates | `~/.hammoc/cert.pem`, `~/.hammoc/key.pem` |
316
- | Session data | `~/.claude/projects/` (managed by Claude Code CLI) |
317
-
318
- ---
319
-
320
- ## HTTPS Setup (for Mobile PWA)
321
-
322
- PWA installation on mobile devices requires HTTPS. Hammoc automatically starts in HTTPS mode when TLS certificates are found at `~/.hammoc/cert.pem` and `~/.hammoc/key.pem`. If no certificates are found, it falls back to HTTP.
323
-
324
- ### Option 1: mkcert (Recommended)
325
-
326
- 1. **Install mkcert:**
327
-
328
- ```bash
329
- # Windows
330
- winget install FiloSottile.mkcert
331
-
332
- # macOS
333
- brew install mkcert
334
-
335
- # Linux
336
- # See https://github.com/FiloSottile/mkcert#installation
337
- ```
338
-
339
- 2. **Create a local CA and generate certificates:**
340
-
341
- ```bash
342
- mkcert -install
343
- mkcert -key-file ~/.hammoc/key.pem -cert-file ~/.hammoc/cert.pem localhost 127.0.0.1 YOUR_LOCAL_IP
344
- ```
345
-
346
- Replace `YOUR_LOCAL_IP` with your PC's IP address (e.g., `192.168.0.10`).
347
-
348
- 3. **Install the root CA on your mobile device:**
349
-
350
- Find the CA certificate location:
351
- ```bash
352
- mkcert -CAROOT
353
- ```
354
-
355
- Transfer `rootCA.pem` to your mobile device, then:
356
- - **Android:** Settings → Security → Install certificate
357
- - **iOS:** Open the file → Install Profile → Settings → General → About → Certificate Trust Settings → Enable
358
-
359
- 4. **Start Hammoc** it will automatically detect the certificates and start in HTTPS mode:
360
-
361
- ```
362
- Hammoc Server running on:
363
- Local: https://localhost:3000
364
- Network: https://192.168.0.10:3000
365
- TLS: enabled (certs from ~/.hammoc/)
366
- ```
367
-
368
- 5. **Open on mobile:** Navigate to `https://YOUR_LOCAL_IP:3000` and install the PWA.
369
-
370
- ### Option 2: Reverse Proxy
371
-
372
- If you already have a reverse proxy (Nginx, Caddy, etc.) handling HTTPS, simply keep Hammoc running in HTTP mode (no certificates needed) and point your proxy to `http://localhost:3000`.
373
-
374
- ---
375
-
376
- ## Environment Variables
377
-
378
- | Variable | Default | Description |
379
- |----------|---------|-------------|
380
- | `PORT` | `3000` | Server port |
381
- | `HOST` | `0.0.0.0` | Bind address |
382
- | `NODE_ENV` | — | Set to `production` for optimized mode |
383
- | `TRUST_PROXY` | `false` | Enable reverse proxy support (Cloudflare Tunnel, nginx, etc.) |
384
- | `CORS_ORIGIN` | `true` | CORS origin (`true` allows any; set a URL to restrict) |
385
- | `RATE_LIMIT` | `200` | Max requests per minute per IP |
386
- | `CHAT_TIMEOUT_MS` | `300000` | Chat response timeout (ms) |
387
- | `LOG_LEVEL` | `INFO`/`DEBUG` | ERROR, WARN, INFO, DEBUG, VERBOSE |
388
- | `TERMINAL_ENABLED` | `true` | Enable/disable terminal feature |
389
- | `TELEGRAM_BOT_TOKEN` | — | Telegram bot token for notifications |
390
- | `TELEGRAM_CHAT_ID` | | Telegram chat ID for notifications |
391
-
392
- ---
393
-
394
- ## License
395
-
396
- AGPL-3.0 See [LICENSE](LICENSE) for details.
397
-
398
- ---
399
-
400
- ## Acknowledgments
401
-
402
- - [Claude Code](https://docs.anthropic.com/en/docs/claude-code) by Anthropic The AI coding assistant that powers Hammoc
403
- - [BMAD-METHOD](https://github.com/bmad-code-org/BMAD-METHOD) by BMad Code The agile AI-driven development methodology integrated into Hammoc
1
+ <p align="center">
2
+ <img src="logo/Hammoc-Header.png" alt="Hammoc" width="480">
3
+ </p>
4
+
5
+ <p align="center">
6
+ <strong>Kick Back. Tap. Ship.</strong><br>
7
+ The web IDE built for AI-driven development workflows — starting with BMAD-METHOD.
8
+ </p>
9
+
10
+ <p align="center">
11
+ <a href="https://www.npmjs.com/package/hammoc"><img src="https://img.shields.io/npm/v/hammoc" alt="npm version"></a>
12
+ <a href="https://www.npmjs.com/package/hammoc"><img src="https://img.shields.io/npm/dm/hammoc" alt="npm downloads"></a>
13
+ <a href="LICENSE"><img src="https://img.shields.io/github/license/starsh2001/hammoc" alt="license"></a>
14
+ </p>
15
+
16
+ <p align="center">
17
+ <a href="docs/MANUAL.md"><strong>User Manual</strong></a> ·
18
+ <a href="#quick-start"><strong>Quick Start</strong></a> ·
19
+ <a href="#features"><strong>Features</strong></a>
20
+ </p>
21
+
22
+ ---
23
+
24
+ ## What is Hammoc?
25
+
26
+ Hammoc is a web IDE optimized for structured AI-driven development methodologies. It currently provides first-class support for the [BMAD-METHOD V4](https://github.com/bmad-code-org/BMAD-METHOD) workflow — with plans to support additional methodologies in the future.
27
+
28
+ Built on top of [Claude Code](https://docs.anthropic.com/en/docs/claude-code), Hammoc provides everything you need to run a full BMAD workflow from your browser: agent switching, PRD-to-queue automation, epic/story tracking, and a Kanban board — all in one place. No terminal hopping, no context switching.
29
+
30
+ Fully responsive and mobile-first. Kick back in your hammock, tap a command on your phone, and let the AI ship it. Inspired by Rich Hickey's *Hammock Driven Development* — the idea that real breakthroughs come when you step back, not when you're grinding at the terminal.
31
+
32
+ ---
33
+
34
+ ## Quick Start
35
+
36
+ ### Prerequisites
37
+
38
+ - **Node.js** >= 18.0.0 (v22 LTS recommended)
39
+ - **Claude Code CLI** installed and authenticated (`claude --version`)
40
+
41
+ ### Install & Run
42
+
43
+ ```bash
44
+ # Run directly (no install needed)
45
+ npx hammoc
46
+
47
+ # Or install globally
48
+ npm install -g hammoc
49
+ hammoc
50
+ ```
51
+
52
+ Open http://localhost:3000 in your browser. First launch guides you through password setup and CLI verification.
53
+
54
+ ### CLI Options
55
+
56
+ ```
57
+ hammoc [options]
58
+
59
+ Options:
60
+ --port <number> Port to listen on (default: 3000, env: PORT)
61
+ --host <string> Host to bind to (default: 0.0.0.0, env: HOST)
62
+ --trust-proxy Enable reverse proxy support (env: TRUST_PROXY)
63
+ --cors-origin <url> Restrict CORS to specific origin (env: CORS_ORIGIN)
64
+ --reset-password Reset the admin password
65
+ -h, --help Show this help message
66
+ -v, --version Show version number
67
+ ```
68
+
69
+ ### Mobile Access
70
+
71
+ Fully responsive. Access from your phone or tablet at `http://<your-ip>:3000` on the same network.
72
+
73
+ ### PWA (Progressive Web App)
74
+
75
+ Hammoc can be installed as a standalone app on your PC or mobile device.
76
+
77
+ - **PC (localhost):** Open `http://localhost:3000` in Chrome → click the install icon in the address bar. No extra setup needed.
78
+ - **Mobile (local network):** Requires HTTPS. See the [HTTPS Setup](#https-setup-for-mobile-pwa) section below.
79
+
80
+ > ⚠️ **Security Notice**
81
+ >
82
+ > Hammoc is designed for **local network / VPN use**. While it includes security hardening for external exposure (see [Remote Access](#remote-access) below), it has not undergone a formal security audit. For maximum safety, run behind a **trusted VPN** (e.g., Tailscale, WireGuard).
83
+
84
+ ### Remote Access
85
+
86
+ If you need to expose Hammoc through a reverse proxy (Cloudflare Tunnel, nginx, etc.):
87
+
88
+ ```bash
89
+ npx hammoc --trust-proxy --cors-origin https://hammoc.yourdomain.com
90
+ ```
91
+
92
+ This enables:
93
+ - **Proxy header support** — Correctly identifies client IPs behind the proxy (CF-Connecting-IP, X-Forwarded-For, X-Real-IP) for localhost/local-network access checks
94
+ - **Secure cookies** — Session cookies are set with `Secure` flag for HTTPS
95
+ - **CORS restriction** — Only the specified origin can make authenticated requests
96
+
97
+ > Hammoc does not apply request rate limiting itself. Configure traffic shaping at your reverse proxy / WAF (e.g. nginx `limit_req`, Cloudflare WAF) — the layer that owns the real client IP and topology.
98
+
99
+ **Security features (always active):**
100
+ - Helmet.js security headers (CSP, X-Frame-Options, HSTS, X-Content-Type-Options)
101
+ - Server management APIs restricted to loopback only (127.0.0.1)
102
+ - Terminal access restricted to local network IPs
103
+ - Login brute-force protection (5 failed attempts 30s lockout per IP)
104
+ - IP validation with strict format checking and `net.isIP()` verification
105
+ - XFF spoofing protection (rightmost IP parsing)
106
+ - Debug endpoints disabled in production
107
+
108
+ ---
109
+
110
+ ## Features
111
+
112
+ ### Why Hammoc?
113
+
114
+ | | Hammoc | Terminal-based IDE | Generic Web IDE |
115
+ |---|:---:|:---:|:---:|
116
+ | BMAD-METHOD workflow | **Built-in** | Manual | N/A |
117
+ | Agent switching (SM, PM, Dev, QA...) | **One tap** | CLI commands | N/A |
118
+ | PRD Queue automation | **Auto-generate** | Copy-paste | N/A |
119
+ | Mobile development | **Full support** | Limited | Partial |
120
+ | Kanban + Epic tracking | **Integrated** | Separate tool | Separate tool |
121
+
122
+ ### Chat Interface
123
+
124
+ Real-time conversations with Claude through a rich web UI.
125
+
126
+ - **Streaming responses** — Messages appear progressively as Claude generates them
127
+ - **Markdown rendering** — Full markdown support with syntax-highlighted code blocks, copy buttons, and inline HTML rendering
128
+ - **Image attachments** — Attach up to 5 images (PNG, JPEG, GIF, WebP) per message with thumbnail display
129
+ - **Tool call visualization** — See what tools Claude uses, with inputs, outputs, and execution time
130
+ - **Diff viewer** — Side-by-side file diff display for code changes
131
+ - **Extended thinking** — View Claude's reasoning process in collapsible blocks
132
+ - **Message edit** — Edit previous messages to branch the conversation into alternative paths
133
+ - **Summarize & Continue** — Compress long conversations with AI-generated summaries
134
+ - **Code rewind** — Restore project files to any earlier point in the conversation
135
+ - **Session fork** — Branch into a new session from any assistant response
136
+ - **Conversation branching** — Navigate between branches with pagination controls, and browse all branches in a read-only viewer
137
+ - **Prompt history** — Navigate previous inputs with arrow keys
138
+ - **Prompt chaining** — Queue up to 10 prompts for sequential execution (server-synced, multi-browser, drag-to-reorder)
139
+ - **Voice input** — Dictate messages using browser speech recognition (Chrome, Edge, Safari)
140
+ - **Context usage monitor** — Track token usage and cost in real-time, with auto-compact on context overflow
141
+ - **Abort generation** — Stop responses with the abort button or ESC key
142
+
143
+ ### Session Management
144
+
145
+ - **Session list** — Browse past conversations with preview, message count, and date
146
+ - **Session search** — Search by name or conversation content (server-side)
147
+ - **Session renaming & deletion** — Keep conversations organized
148
+ - **Quick session panel** — Access sessions without leaving the chat
149
+ - **Active streaming indicator** — See which sessions are currently active
150
+
151
+ ### Slash Commands, Snippets & Favorites
152
+
153
+ - **Command palette** — Type `/` to browse available commands with autocomplete
154
+ - **Prompt snippets** — Type `%` to insert reusable prompt templates with argument substitution, context blocks, and multi-prompt chaining
155
+ - **Snippet hierarchy** — Project, global, and bundled snippets with override support
156
+ - **Favorites bar** — Pin up to 20 frequently used commands above the input
157
+ - **Star favorites** — Mark up to 10 star commands for quick access
158
+ - **Drag-to-reorder** — Customize favorite command order
159
+ - **Agent-specific commands** — Context-aware commands per BMad agent
160
+
161
+ ### Model & Permission Control
162
+
163
+ - **Model selector** — Choose between Claude Sonnet, Opus, and Haiku variants (including Opus 4.7 with 1M context) with model name displayed on the button
164
+ - **Thinking effort** — Adjust reasoning intensity (Low / Medium / High, plus Max on 4.6 models and XHigh on Opus 4.7)
165
+ - **Permission modes** — Plan, Ask (default), Auto, or Bypass
166
+ - **Per-project overrides** — Different settings per project
167
+
168
+ ### Project Management
169
+
170
+ - **Project list** — Browse all projects with session counts and last activity
171
+ - **Project dashboard** — Real-time status: active chats, queue runners, terminals
172
+ - **Project creation** — Create new projects with optional BMad Method initialization
173
+ - **Per-project Settings tab** — Each project carries its own Settings tab (model, permission, budget) plus the Harness Workbench (see below). No more switching to the global Settings page and picking a project from a dropdown
174
+ - **Hide/unhide projects** — Keep the list clean
175
+
176
+ ### Harness Workbench
177
+
178
+ Edit the `.claude/` configuration tree from inside Hammoc no need to hand-edit JSON or Markdown on disk.
179
+
180
+ - **Plugins, Skills, MCP, Hooks, Slash Commands, Sub-agents** — Card-grid panels for each, with project ↔ global copy actions and conflict dialogs
181
+ - **CLAUDE.md editor** — Two-column edit of project and global instruction documents with live Markdown preview
182
+ - **Snippets & Favorites** — Manage Hammoc `%snippets` (project / global / bundled) alongside Claude Code slash-command favorites in a single panel
183
+ - **Share badges + mode banner** — See at a glance which files are git-tracked vs local, so you know which edits will reach teammates
184
+ - **Static lint (7 rules)** — Surfaces duplicate names, invalid hook regex, missing env vars, malformed MCP URLs, non-standard agent tools, etc.; per-rule on/off preferences
185
+ - **Secret-on-shared guard** — Blocks plaintext API keys / tokens from sneaking into committed config files, with one-click "move to local sibling" remediation
186
+ - **Fullscreen editor overlay** — Maximize any body field (skill, command, agent, CLAUDE.md, snippet) into a fullscreen CodeMirror
187
+
188
+ ### File Explorer & Editor
189
+
190
+ - **Grid & List views** — Finder-style grid or traditional list layout
191
+ - **Tree navigation** — Directory hierarchy with breadcrumbs
192
+ - **Text editor** — Syntax highlighting with save (Ctrl+S) and binary file download
193
+ - **Markdown preview** — Toggle between edit and preview modes
194
+ - **Image viewer** — Full-screen viewer with zoom, fit-to-screen/width/height and 1:1 toggles, touch gestures (pinch, swipe, pan), and multi-image navigation across attachments or folder siblings
195
+ - **External change detection** — Editor alerts you when an open file is modified or deleted on disk, with reload / overwrite options for stale-write conflicts
196
+ - **File operations** — Create, rename, and delete files and folders
197
+
198
+ ### Git Integration
199
+
200
+ - **Status panel** — Staged, unstaged, and untracked changes at a glance
201
+ - **Stage & commit** — Stage files individually or all at once, write commit messages
202
+ - **Branch management** — Create, switch, and view branches
203
+ - **Pull & Push** — Sync with remote repositories
204
+ - **Quick Git panel** — Lightweight Git access from the chat view
205
+ - **AI-assisted split-commit** — One-click chip delegates "split this messy working tree into logical commits" to Claude in a fresh session
206
+
207
+ ### Terminal
208
+
209
+ - **PTY emulation** Full terminal emulation powered by xterm.js
210
+ - **Multiple tabs** — Run several terminal sessions simultaneously
211
+ - **Security** — Restricted to local network by default; configurable via settings
212
+
213
+ ### Queue Runner (Batch Automation)
214
+
215
+ Automate repetitive prompt sequences.
216
+
217
+ - **Queue editor** — Write prompt sequences line by line, with a sticky line-number gutter
218
+ - **Special commands** — `@new`, `@save`, `@load`, `@pause`, `@model`, `@delay`, `@pauseword`, `@loop`/`@end`, `@label`/`@jumpif` (forward jumps), `@(/@)`, `#` comments
219
+ - **Execution control** — Start, pause (deferred), resume, abort, and edit remaining items while paused
220
+ - **Templates** — Save and load reusable queue scripts; ships a ready-to-use BMad story workflow template in the source repo
221
+ - **Story-based generation** — Auto-generate queue from PRD epics and stories
222
+ - **Variable substitution** — Use `{story_num}`, `{epic_num}`, `{story_index}`, `{story_title}`, `{date}` in templates
223
+
224
+ ### Project Board (Issue Tracking)
225
+
226
+ - **Kanban board** — Visual cards across customizable status columns; issue cards show a `#N` prefix matching their `ISSUE-N.md` file
227
+ - **List view** — Tabular alternative with sorting and filtering
228
+ - **Issue types** — Bug, Improvement
229
+ - **Severity levels** — Low, Medium, High, Critical
230
+ - **Status workflow** — Open → Draft → Approved → In Progress → Blocked → Review → Done → Closed
231
+ - **Mobile Kanban** Touch-optimized board for small screens
232
+
233
+ ### Settings
234
+
235
+ - **Theme** — Dark, Light, or System
236
+ - **Language** — English, 中文, 日本語, 한국어, Español, Português
237
+ - **Chat timeout** — 1m, 3m, 5m (default), 10m, 30m
238
+ - **Web Push & Telegram notifications** — Get notified on permission requests, completions, and errors
239
+ - **Claude account & usage** — Inspect the linked Claude Code account plus 5h / 7d usage quotas with live refresh
240
+ - **System prompt editing** — Customize Claude's behavior per project
241
+ - **Advanced** Server restart, software updates, SDK parameters (thinking tokens, turns, budget now applied to both chat and queue runs)
242
+
243
+ ---
244
+
245
+ ## BMAD-METHOD V4 Integration
246
+
247
+ Hammoc is the most convenient way to run a full [BMAD-METHOD](https://github.com/bmad-code-org/BMAD-METHOD) (Breakthrough Method for Agile AI-Driven Development) workflow. Every step — from project inception to QA — is built into the IDE.
248
+
249
+ - **One-click BMad setup** — Initialize `.bmad-core` in any project with version selection
250
+ - **BMad Agent switching** — Instantly switch between agents (SM, PM, Architect, Dev, QA, PO, etc.) in chat with a single tap
251
+ - **Slash commands per agent** — Context-aware `/commands` that change based on the active BMad agent
252
+ - **PRD Queue automation** Auto-generate prompt queues directly from your PRD epics and stories
253
+ - **Project overview dashboard** Visual status showing PRD completion, epic progress, and story status
254
+ - **Kanban board integration** Track epics and stories with status workflow, promote/validate actions
255
+ - **Story workflows** Start development, request QA, and apply fixes — all through the board UI
256
+
257
+ > **Methodology support roadmap:** Hammoc is designed to be methodology-agnostic. BMAD-METHOD V4 is the first supported workflow, with more development methodologies planned for future releases.
258
+
259
+ For detailed BMAD-METHOD documentation, visit the [official repository](https://github.com/bmad-code-org/BMAD-METHOD).
260
+
261
+ ---
262
+
263
+ ## Keyboard Shortcuts
264
+
265
+ | Shortcut | Action |
266
+ |----------|--------|
267
+ | `Enter` | Send message (desktop) |
268
+ | `Shift+Enter` | New line in message |
269
+ | `ESC` | Abort generation |
270
+ | `Ctrl+S` | Save file in editor |
271
+ | `Ctrl+=` `Ctrl+-` | Terminal font size |
272
+ | `Ctrl+0` | Reset terminal font size |
273
+ | `%` | Open snippet autocomplete palette |
274
+ | `↑` / `↓` | Navigate prompt history |
275
+ | `Alt+1/2/3/4` | Toggle quick panel (Sessions/Files/Git/Terminal) |
276
+
277
+ ---
278
+
279
+ ## Architecture
280
+
281
+ Hammoc is a monorepo with three packages:
282
+
283
+ ```
284
+ hammoc/
285
+ ├── bin/hammoc.js # CLI entry point
286
+ ├── packages/
287
+ │ ├── shared/ # Shared types, constants, utilities
288
+ │ ├── server/ # Express + Socket.io backend
289
+ │ └── client/ # React + Vite frontend
290
+ └── scripts/
291
+ └── postinstall.cjs # Shared package linker
292
+ ```
293
+
294
+ **Tech Stack:**
295
+ - **Frontend:** React 18, Vite, Tailwind CSS, Zustand, Socket.io Client, xterm.js
296
+ - **Backend:** Node.js, Express, Socket.io, node-pty, Claude Agent SDK
297
+ - **Shared:** TypeScript, Zod validation
298
+
299
+ ---
300
+
301
+ ## Development
302
+
303
+ ```bash
304
+ git clone https://github.com/starsh2001/hammoc.git
305
+ cd hammoc
306
+ npm install
307
+ npm run dev
308
+ ```
309
+
310
+ | Command | Description |
311
+ |---------|-------------|
312
+ | `npm run dev` | Start all packages in development mode |
313
+ | `npm run build` | Build all packages for production |
314
+ | `npm start` | Run server in production mode |
315
+ | `npm test` | Run all tests |
316
+ | `npm run lint` | Run ESLint on all packages |
317
+ | `npm run typecheck` | Run TypeScript type checking |
318
+
319
+ ---
320
+
321
+ ## Data Storage
322
+
323
+ | Data | Location |
324
+ |------|----------|
325
+ | App config & password | `~/.hammoc/config.json` |
326
+ | User preferences | `~/.hammoc/preferences.json` |
327
+ | Queue templates | `<project-root>/.hammoc/queue-templates.json` (per project) |
328
+ | Chain failures | `~/.hammoc/chain-failures/<sessionId>.json` (per session) |
329
+ | Snippets (global) | `~/.hammoc/snippets/` (shared across projects) |
330
+ | Snippets (project) | `<project-root>/.hammoc/snippets/` (per project) |
331
+ | Harness items (global) | `~/.claude/` (skills, agents, commands, hooks, `CLAUDE.md`, `.mcp.json`, `settings.json`) |
332
+ | Harness items (project) | `<project-root>/.claude/` (same layout; project wins on conflict) |
333
+ | TLS certificates | `~/.hammoc/cert.pem`, `~/.hammoc/key.pem` |
334
+ | Manual shards (synced) | `~/.hammoc/docs/manual/` and `~/.hammoc/docs/.manual-version` (auto-synced from package on server boot) |
335
+ | Internals docs (synced) | `~/.hammoc/docs/internals/` (agent-only mechanism reference; also re-synced on package version change) |
336
+ | Session data | `~/.claude/projects/` (managed by Claude Code CLI) |
337
+
338
+ ---
339
+
340
+ ## HTTPS Setup (for Mobile PWA)
341
+
342
+ PWA installation on mobile devices requires HTTPS. Hammoc automatically starts in HTTPS mode when TLS certificates are found at `~/.hammoc/cert.pem` and `~/.hammoc/key.pem`. If no certificates are found, it falls back to HTTP.
343
+
344
+ ### Option 1: mkcert (Recommended)
345
+
346
+ 1. **Install mkcert:**
347
+
348
+ ```bash
349
+ # Windows
350
+ winget install FiloSottile.mkcert
351
+
352
+ # macOS
353
+ brew install mkcert
354
+
355
+ # Linux
356
+ # See https://github.com/FiloSottile/mkcert#installation
357
+ ```
358
+
359
+ 2. **Create a local CA and generate certificates:**
360
+
361
+ ```bash
362
+ mkcert -install
363
+ mkcert -key-file ~/.hammoc/key.pem -cert-file ~/.hammoc/cert.pem localhost 127.0.0.1 YOUR_LOCAL_IP
364
+ ```
365
+
366
+ Replace `YOUR_LOCAL_IP` with your PC's IP address (e.g., `192.168.0.10`).
367
+
368
+ 3. **Install the root CA on your mobile device:**
369
+
370
+ Find the CA certificate location:
371
+ ```bash
372
+ mkcert -CAROOT
373
+ ```
374
+
375
+ Transfer `rootCA.pem` to your mobile device, then:
376
+ - **Android:** Settings → Security → Install certificate
377
+ - **iOS:** Open the file → Install Profile → Settings → General → About → Certificate Trust Settings → Enable
378
+
379
+ 4. **Start Hammoc** — it will automatically detect the certificates and start in HTTPS mode:
380
+
381
+ ```
382
+ Hammoc Server running on:
383
+ Local: https://localhost:3000
384
+ Network: https://192.168.0.10:3000
385
+ TLS: enabled (certs from ~/.hammoc/)
386
+ ```
387
+
388
+ 5. **Open on mobile:** Navigate to `https://YOUR_LOCAL_IP:3000` and install the PWA.
389
+
390
+ ### Option 2: Reverse Proxy
391
+
392
+ If you already have a reverse proxy (Nginx, Caddy, etc.) handling HTTPS, simply keep Hammoc running in HTTP mode (no certificates needed) and point your proxy to `http://localhost:3000`.
393
+
394
+ ---
395
+
396
+ ## Environment Variables
397
+
398
+ | Variable | Default | Description |
399
+ |----------|---------|-------------|
400
+ | `PORT` | `3000` | Server port |
401
+ | `HOST` | `0.0.0.0` | Bind address |
402
+ | `NODE_ENV` | | Set to `production` for optimized mode |
403
+ | `TRUST_PROXY` | `false` | Enable reverse proxy support (Cloudflare Tunnel, nginx, etc.) |
404
+ | `CORS_ORIGIN` | `true` | CORS origin (`true` allows any; set a URL to restrict) |
405
+ | `CHAT_TIMEOUT_MS` | `300000` | Chat response timeout (ms) |
406
+ | `LOG_LEVEL` | `INFO`/`DEBUG` | ERROR, WARN, INFO, DEBUG, VERBOSE |
407
+ | `TERMINAL_ENABLED` | `true` | Enable/disable terminal feature |
408
+ | `TELEGRAM_BOT_TOKEN` | — | Telegram bot token for notifications |
409
+ | `TELEGRAM_CHAT_ID` | — | Telegram chat ID for notifications |
410
+
411
+ ---
412
+
413
+ ## License
414
+
415
+ AGPL-3.0 — See [LICENSE](LICENSE) for details.
416
+
417
+ ---
418
+
419
+ ## Acknowledgments
420
+
421
+ - [Claude Code](https://docs.anthropic.com/en/docs/claude-code) by Anthropic — The AI coding assistant that powers Hammoc
422
+ - [BMAD-METHOD](https://github.com/bmad-code-org/BMAD-METHOD) by BMad Code — The agile AI-driven development methodology integrated into Hammoc