@ngxtm/devkit 2.1.0 → 3.0.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 (533) hide show
  1. package/cli/detect.js +292 -0
  2. package/cli/index.js +204 -92
  3. package/cli/init.js +245 -0
  4. package/cli/update.js +243 -0
  5. package/cli/utils.js +195 -0
  6. package/package.json +16 -20
  7. package/rules-index.json +76 -0
  8. package/scripts/generate-index.js +223 -0
  9. package/scripts/merge-commands.js +290 -0
  10. package/scripts/organize-rules.js +226 -0
  11. package/templates/base/hooks/lib/ck-config-utils.cjs +769 -0
  12. package/templates/base/hooks/lib/ck-paths.cjs +110 -0
  13. package/templates/base/hooks/lib/colors.cjs +95 -0
  14. package/templates/base/hooks/lib/config-counter.cjs +103 -0
  15. package/templates/base/hooks/lib/context-builder.cjs +600 -0
  16. package/templates/base/hooks/lib/context-tracker.cjs +335 -0
  17. package/templates/base/hooks/lib/privacy-checker.cjs +297 -0
  18. package/templates/base/hooks/lib/project-detector.cjs +430 -0
  19. package/templates/base/hooks/lib/scout-checker.cjs +172 -0
  20. package/templates/base/hooks/lib/transcript-parser.cjs +164 -0
  21. package/templates/base/hooks/privacy-block.cjs +145 -0
  22. package/agents/backend-engineer.md +0 -154
  23. package/agents/brainstormer.md +0 -169
  24. package/agents/business-analyst.md +0 -166
  25. package/agents/database-architect.md +0 -159
  26. package/agents/debugger.md +0 -155
  27. package/agents/designer.md +0 -150
  28. package/agents/devops-engineer.md +0 -155
  29. package/agents/docs-manager.md +0 -171
  30. package/agents/frontend-engineer.md +0 -159
  31. package/agents/game-engineer.md +0 -148
  32. package/agents/mobile-engineer.md +0 -149
  33. package/agents/performance-engineer.md +0 -152
  34. package/agents/planner.md +0 -161
  35. package/agents/project-manager.md +0 -160
  36. package/agents/researcher.md +0 -146
  37. package/agents/reviewer.md +0 -155
  38. package/agents/scouter.md +0 -157
  39. package/agents/security-engineer.md +0 -154
  40. package/agents/tech-lead.md +0 -159
  41. package/agents/tester.md +0 -157
  42. package/agents-claudekit/brainstormer.md +0 -113
  43. package/agents-claudekit/code-reviewer.md +0 -157
  44. package/agents-claudekit/code-simplifier.md +0 -42
  45. package/agents-claudekit/copywriter.md +0 -110
  46. package/agents-claudekit/database-admin.md +0 -92
  47. package/agents-claudekit/debugger.md +0 -137
  48. package/agents-claudekit/docs-manager.md +0 -208
  49. package/agents-claudekit/fullstack-developer.md +0 -95
  50. package/agents-claudekit/git-manager.md +0 -394
  51. package/agents-claudekit/journal-writer.md +0 -113
  52. package/agents-claudekit/mcp-manager.md +0 -93
  53. package/agents-claudekit/planner.md +0 -108
  54. package/agents-claudekit/project-manager.md +0 -125
  55. package/agents-claudekit/researcher.md +0 -38
  56. package/agents-claudekit/scout-external.md +0 -141
  57. package/agents-claudekit/scout.md +0 -107
  58. package/agents-claudekit/tester.md +0 -105
  59. package/agents-claudekit/ui-ux-designer.md +0 -236
  60. package/commands/ask.md +0 -64
  61. package/commands/brainstorm.md +0 -64
  62. package/commands/code.md +0 -64
  63. package/commands/cook.md +0 -64
  64. package/commands/debug.md +0 -64
  65. package/commands/design/fast.md +0 -134
  66. package/commands/fix/fast.md +0 -84
  67. package/commands/fix/hard.md +0 -116
  68. package/commands/fix.md +0 -64
  69. package/commands/plan/fast.md +0 -78
  70. package/commands/plan/hard.md +0 -131
  71. package/commands/plan.md +0 -64
  72. package/commands/test.md +0 -64
  73. package/matrix-skills/_index.yaml +0 -275
  74. package/matrix-skills/ai-ml.yaml +0 -353
  75. package/matrix-skills/architecture.yaml +0 -93
  76. package/matrix-skills/backend.yaml +0 -280
  77. package/matrix-skills/cloud.yaml +0 -112
  78. package/matrix-skills/data.yaml +0 -74
  79. package/matrix-skills/design.yaml +0 -98
  80. package/matrix-skills/devops.yaml +0 -200
  81. package/matrix-skills/frontend.yaml +0 -200
  82. package/matrix-skills/gaming.yaml +0 -39
  83. package/matrix-skills/languages.yaml +0 -160
  84. package/matrix-skills/management.yaml +0 -50
  85. package/matrix-skills/mcp.yaml +0 -82
  86. package/matrix-skills/mobile.yaml +0 -85
  87. package/matrix-skills/performance.yaml +0 -23
  88. package/matrix-skills/planning.yaml +0 -117
  89. package/matrix-skills/quality.yaml +0 -195
  90. package/matrix-skills/research.yaml +0 -106
  91. package/matrix-skills/security.yaml +0 -293
  92. package/matrix-skills/tools.yaml +0 -352
  93. package/output-styles/coding-level-0-eli5.md +0 -103
  94. package/output-styles/coding-level-1-junior.md +0 -124
  95. package/output-styles/coding-level-2-mid.md +0 -146
  96. package/output-styles/coding-level-3-senior.md +0 -148
  97. package/output-styles/coding-level-4-lead.md +0 -159
  98. package/output-styles/coding-level-5-god.md +0 -91
  99. package/rules/README.md +0 -141
  100. package/rules/metadata.json +0 -54
  101. package/settings.json +0 -3
  102. package/statusline.cjs +0 -500
  103. package/statusline.ps1 +0 -307
  104. package/statusline.sh +0 -237
  105. package/workflows/development-rules.md +0 -42
  106. package/workflows/documentation-management.md +0 -121
  107. package/workflows/orchestration-protocol.md +0 -16
  108. package/workflows/primary-workflow.md +0 -45
  109. /package/{commands → merged-commands}/ask/fast.md +0 -0
  110. /package/{commands → merged-commands}/ask/hard.md +0 -0
  111. /package/{commands-claudekit → merged-commands}/ask.md +0 -0
  112. /package/{commands → merged-commands}/auto.md +0 -0
  113. /package/{commands-claudekit → merged-commands}/bootstrap/auto/fast.md +0 -0
  114. /package/{commands-claudekit → merged-commands}/bootstrap/auto/parallel.md +0 -0
  115. /package/{commands-claudekit → merged-commands}/bootstrap/auto.md +0 -0
  116. /package/{commands-claudekit → merged-commands}/bootstrap.md +0 -0
  117. /package/{commands → merged-commands}/brainstorm/fast.md +0 -0
  118. /package/{commands → merged-commands}/brainstorm/hard.md +0 -0
  119. /package/{commands-claudekit → merged-commands}/brainstorm.md +0 -0
  120. /package/{commands-claudekit → merged-commands}/ck-help.md +0 -0
  121. /package/{commands-claudekit → merged-commands}/code/auto.md +0 -0
  122. /package/{commands → merged-commands}/code/fast.md +0 -0
  123. /package/{commands → merged-commands}/code/hard.md +0 -0
  124. /package/{commands-claudekit → merged-commands}/code/no-test.md +0 -0
  125. /package/{commands-claudekit → merged-commands}/code/parallel.md +0 -0
  126. /package/{commands-claudekit → merged-commands}/code.md +0 -0
  127. /package/{commands-claudekit → merged-commands}/coding-level.md +0 -0
  128. /package/{commands-claudekit → merged-commands}/content/cro.md +0 -0
  129. /package/{commands-claudekit → merged-commands}/content/enhance.md +0 -0
  130. /package/{commands-claudekit → merged-commands}/content/fast.md +0 -0
  131. /package/{commands-claudekit → merged-commands}/content/good.md +0 -0
  132. /package/{commands-claudekit → merged-commands}/cook/auto/fast.md +0 -0
  133. /package/{commands-claudekit → merged-commands}/cook/auto/parallel.md +0 -0
  134. /package/{commands-claudekit → merged-commands}/cook/auto.md +0 -0
  135. /package/{commands → merged-commands}/cook/fast.md +0 -0
  136. /package/{commands → merged-commands}/cook/hard.md +0 -0
  137. /package/{commands-claudekit → merged-commands}/cook.md +0 -0
  138. /package/{commands → merged-commands}/debug/fast.md +0 -0
  139. /package/{commands → merged-commands}/debug/hard.md +0 -0
  140. /package/{commands-claudekit → merged-commands}/debug.md +0 -0
  141. /package/{commands → merged-commands}/deploy/check.md +0 -0
  142. /package/{commands → merged-commands}/deploy/preview.md +0 -0
  143. /package/{commands → merged-commands}/deploy/production.md +0 -0
  144. /package/{commands → merged-commands}/deploy/rollback.md +0 -0
  145. /package/{commands → merged-commands}/deploy.md +0 -0
  146. /package/{commands-claudekit → merged-commands}/design/3d.md +0 -0
  147. /package/{commands-claudekit → merged-commands}/design/describe.md +0 -0
  148. /package/{commands-claudekit → merged-commands}/design/fast.md +0 -0
  149. /package/{commands-claudekit → merged-commands}/design/good.md +0 -0
  150. /package/{commands → merged-commands}/design/hard.md +0 -0
  151. /package/{commands-claudekit → merged-commands}/design/screenshot.md +0 -0
  152. /package/{commands-claudekit → merged-commands}/design/video.md +0 -0
  153. /package/{commands → merged-commands}/design.md +0 -0
  154. /package/{commands → merged-commands}/docs/audit.md +0 -0
  155. /package/{commands → merged-commands}/docs/business.md +0 -0
  156. /package/{commands → merged-commands}/docs/core.md +0 -0
  157. /package/{commands-claudekit → merged-commands}/docs/init.md +0 -0
  158. /package/{commands-claudekit → merged-commands}/docs/summarize.md +0 -0
  159. /package/{commands-claudekit → merged-commands}/docs/update.md +0 -0
  160. /package/{commands → merged-commands}/docs.md +0 -0
  161. /package/{commands-claudekit → merged-commands}/fix/ci.md +0 -0
  162. /package/{commands-claudekit → merged-commands}/fix/fast.md +0 -0
  163. /package/{commands-claudekit → merged-commands}/fix/hard.md +0 -0
  164. /package/{commands-claudekit → merged-commands}/fix/logs.md +0 -0
  165. /package/{commands-claudekit → merged-commands}/fix/parallel.md +0 -0
  166. /package/{commands-claudekit → merged-commands}/fix/test.md +0 -0
  167. /package/{commands-claudekit → merged-commands}/fix/types.md +0 -0
  168. /package/{commands-claudekit → merged-commands}/fix/ui.md +0 -0
  169. /package/{commands-claudekit → merged-commands}/fix.md +0 -0
  170. /package/{commands-claudekit → merged-commands}/git/cm.md +0 -0
  171. /package/{commands-claudekit → merged-commands}/git/cp.md +0 -0
  172. /package/{commands-claudekit → merged-commands}/git/merge.md +0 -0
  173. /package/{commands-claudekit → merged-commands}/git/pr.md +0 -0
  174. /package/{commands-claudekit → merged-commands}/integrate/polar.md +0 -0
  175. /package/{commands-claudekit → merged-commands}/integrate/sepay.md +0 -0
  176. /package/{commands-claudekit → merged-commands}/journal.md +0 -0
  177. /package/{commands-claudekit → merged-commands}/kanban.md +0 -0
  178. /package/{commands-claudekit → merged-commands}/plan/archive.md +0 -0
  179. /package/{commands-claudekit → merged-commands}/plan/ci.md +0 -0
  180. /package/{commands-claudekit → merged-commands}/plan/cro.md +0 -0
  181. /package/{commands-claudekit → merged-commands}/plan/fast.md +0 -0
  182. /package/{commands-claudekit → merged-commands}/plan/hard.md +0 -0
  183. /package/{commands-claudekit → merged-commands}/plan/parallel.md +0 -0
  184. /package/{commands-claudekit → merged-commands}/plan/two.md +0 -0
  185. /package/{commands-claudekit → merged-commands}/plan/validate.md +0 -0
  186. /package/{commands-claudekit → merged-commands}/plan.md +0 -0
  187. /package/{commands-claudekit → merged-commands}/preview.md +0 -0
  188. /package/{commands-claudekit → merged-commands}/review/codebase/parallel.md +0 -0
  189. /package/{commands-claudekit → merged-commands}/review/codebase.md +0 -0
  190. /package/{commands → merged-commands}/review/fast.md +0 -0
  191. /package/{commands → merged-commands}/review/hard.md +0 -0
  192. /package/{commands → merged-commands}/review.md +0 -0
  193. /package/{commands-claudekit → merged-commands}/scout/ext.md +0 -0
  194. /package/{commands-claudekit → merged-commands}/scout.md +0 -0
  195. /package/{commands-claudekit → merged-commands}/skill/add.md +0 -0
  196. /package/{commands-claudekit → merged-commands}/skill/create.md +0 -0
  197. /package/{commands-claudekit → merged-commands}/skill/fix-logs.md +0 -0
  198. /package/{commands-claudekit → merged-commands}/skill/optimize/auto.md +0 -0
  199. /package/{commands-claudekit → merged-commands}/skill/optimize.md +0 -0
  200. /package/{commands-claudekit → merged-commands}/skill/plan.md +0 -0
  201. /package/{commands-claudekit → merged-commands}/skill/update.md +0 -0
  202. /package/{commands → merged-commands}/test/fast.md +0 -0
  203. /package/{commands → merged-commands}/test/hard.md +0 -0
  204. /package/{commands-claudekit → merged-commands}/test/ui.md +0 -0
  205. /package/{commands-claudekit → merged-commands}/test.md +0 -0
  206. /package/{commands-claudekit → merged-commands}/use-mcp.md +0 -0
  207. /package/{commands-claudekit → merged-commands}/watzup.md +0 -0
  208. /package/{commands-claudekit → merged-commands}/worktree.md +0 -0
  209. /package/{rules → templates/dart/rules}/dart/best-practices/SKILL.md +0 -0
  210. /package/{rules → templates/dart/rules}/dart/language/SKILL.md +0 -0
  211. /package/{rules → templates/dart/rules}/dart/tooling/SKILL.md +0 -0
  212. /package/{rules → templates/flutter/rules}/flutter/auto-route-navigation/SKILL.md +0 -0
  213. /package/{rules → templates/flutter/rules}/flutter/auto-route-navigation/references/REFERENCE.md +0 -0
  214. /package/{rules → templates/flutter/rules}/flutter/auto-route-navigation/references/router-config.md +0 -0
  215. /package/{rules → templates/flutter/rules}/flutter/bloc-state-management/SKILL.md +0 -0
  216. /package/{rules → templates/flutter/rules}/flutter/bloc-state-management/references/REFERENCE.md +0 -0
  217. /package/{rules → templates/flutter/rules}/flutter/bloc-state-management/references/auth-bloc-example.md +0 -0
  218. /package/{rules → templates/flutter/rules}/flutter/bloc-state-management/references/equatable-usage.md +0 -0
  219. /package/{rules → templates/flutter/rules}/flutter/bloc-state-management/references/property-based-state.md +0 -0
  220. /package/{rules → templates/flutter/rules}/flutter/bloc.rule.md +0 -0
  221. /package/{rules → templates/flutter/rules}/flutter/cicd/SKILL.md +0 -0
  222. /package/{rules → templates/flutter/rules}/flutter/cicd/references/advanced-workflow.md +0 -0
  223. /package/{rules → templates/flutter/rules}/flutter/cicd/references/fastlane.md +0 -0
  224. /package/{rules → templates/flutter/rules}/flutter/cicd/references/github-actions.md +0 -0
  225. /package/{rules → templates/flutter/rules}/flutter/dependency-injection/SKILL.md +0 -0
  226. /package/{rules → templates/flutter/rules}/flutter/dependency-injection/references/REFERENCE.md +0 -0
  227. /package/{rules → templates/flutter/rules}/flutter/dependency-injection/references/modules.md +0 -0
  228. /package/{rules → templates/flutter/rules}/flutter/error-handling/SKILL.md +0 -0
  229. /package/{rules → templates/flutter/rules}/flutter/error-handling/references/REFERENCE.md +0 -0
  230. /package/{rules → templates/flutter/rules}/flutter/error-handling/references/error-mapping.md +0 -0
  231. /package/{rules → templates/flutter/rules}/flutter/feature-based-clean-architecture/SKILL.md +0 -0
  232. /package/{rules → templates/flutter/rules}/flutter/feature-based-clean-architecture/references/REFERENCE.md +0 -0
  233. /package/{rules → templates/flutter/rules}/flutter/feature-based-clean-architecture/references/folder-structure.md +0 -0
  234. /package/{rules → templates/flutter/rules}/flutter/getx-navigation/SKILL.md +0 -0
  235. /package/{rules → templates/flutter/rules}/flutter/getx-navigation/references/app-pages.md +0 -0
  236. /package/{rules → templates/flutter/rules}/flutter/getx-navigation/references/middleware-example.md +0 -0
  237. /package/{rules → templates/flutter/rules}/flutter/getx-state-management/SKILL.md +0 -0
  238. /package/{rules → templates/flutter/rules}/flutter/getx-state-management/references/binding-example.md +0 -0
  239. /package/{rules → templates/flutter/rules}/flutter/getx-state-management/references/reactive-vs-simple.md +0 -0
  240. /package/{rules → templates/flutter/rules}/flutter/go-router-navigation/SKILL.md +0 -0
  241. /package/{rules → templates/flutter/rules}/flutter/idiomatic-flutter/SKILL.md +0 -0
  242. /package/{rules → templates/flutter/rules}/flutter/layer-based-clean-architecture/SKILL.md +0 -0
  243. /package/{rules → templates/flutter/rules}/flutter/layer-based-clean-architecture/references/REFERENCE.md +0 -0
  244. /package/{rules → templates/flutter/rules}/flutter/layer-based-clean-architecture/references/repository-mapping.md +0 -0
  245. /package/{rules → templates/flutter/rules}/flutter/localization/SKILL.md +0 -0
  246. /package/{rules → templates/flutter/rules}/flutter/localization/references/REFERENCE.md +0 -0
  247. /package/{rules → templates/flutter/rules}/flutter/localization/references/sheet-loader.md +0 -0
  248. /package/{rules → templates/flutter/rules}/flutter/navigator-v1-navigation/SKILL.md +0 -0
  249. /package/{rules → templates/flutter/rules}/flutter/navigator-v1-navigation/references/on-generate-route.md +0 -0
  250. /package/{rules → templates/flutter/rules}/flutter/performance/SKILL.md +0 -0
  251. /package/{rules → templates/flutter/rules}/flutter/retrofit-networking/SKILL.md +0 -0
  252. /package/{rules → templates/flutter/rules}/flutter/retrofit-networking/references/REFERENCE.md +0 -0
  253. /package/{rules → templates/flutter/rules}/flutter/retrofit-networking/references/token-refresh.md +0 -0
  254. /package/{rules → templates/flutter/rules}/flutter/riverpod-state-management/SKILL.md +0 -0
  255. /package/{rules → templates/flutter/rules}/flutter/riverpod-state-management/references/architecture.md +0 -0
  256. /package/{rules → templates/flutter/rules}/flutter/riverpod-state-management/references/best-practices.md +0 -0
  257. /package/{rules → templates/flutter/rules}/flutter/riverpod-state-management/references/testing.md +0 -0
  258. /package/{rules → templates/flutter/rules}/flutter/riverpod.rule.md +0 -0
  259. /package/{rules → templates/flutter/rules}/flutter/security/SKILL.md +0 -0
  260. /package/{rules → templates/flutter/rules}/flutter/security/references/REFERENCE.md +0 -0
  261. /package/{rules → templates/flutter/rules}/flutter/security/references/network-security.md +0 -0
  262. /package/{rules → templates/flutter/rules}/flutter/testing/SKILL.md +0 -0
  263. /package/{rules → templates/flutter/rules}/flutter/testing/references/REFERENCE.md +0 -0
  264. /package/{rules → templates/flutter/rules}/flutter/testing/references/bloc-testing.md +0 -0
  265. /package/{rules → templates/flutter/rules}/flutter/testing/references/integration-testing.md +0 -0
  266. /package/{rules → templates/flutter/rules}/flutter/testing/references/robot-pattern.md +0 -0
  267. /package/{rules → templates/flutter/rules}/flutter/testing/references/unit-testing.md +0 -0
  268. /package/{rules → templates/flutter/rules}/flutter/testing/references/widget-testing.md +0 -0
  269. /package/{rules → templates/flutter/rules}/flutter/widgets/SKILL.md +0 -0
  270. /package/{rules → templates/golang/rules}/golang/chi-router/SKILL.md +0 -0
  271. /package/{rules → templates/golang/rules}/golang/chi-router/references/REFERENCE.md +0 -0
  272. /package/{rules → templates/golang/rules}/golang/chi-router/references/routing-patterns.md +0 -0
  273. /package/{rules → templates/golang/rules}/golang/cobra-cli/SKILL.md +0 -0
  274. /package/{rules → templates/golang/rules}/golang/cobra-cli/references/REFERENCE.md +0 -0
  275. /package/{rules → templates/golang/rules}/golang/cobra-cli/references/command-patterns.md +0 -0
  276. /package/{rules → templates/golang/rules}/golang/core/SKILL.md +0 -0
  277. /package/{rules → templates/golang/rules}/golang/core/references/REFERENCE.md +0 -0
  278. /package/{rules → templates/golang/rules}/golang/core/references/concurrency-patterns.md +0 -0
  279. /package/{rules → templates/golang/rules}/golang/core/references/error-handling.md +0 -0
  280. /package/{rules → templates/golang/rules}/golang/echo-framework/SKILL.md +0 -0
  281. /package/{rules → templates/golang/rules}/golang/echo-framework/references/REFERENCE.md +0 -0
  282. /package/{rules → templates/golang/rules}/golang/echo-framework/references/middleware-patterns.md +0 -0
  283. /package/{rules → templates/golang/rules}/golang/echo-framework/references/routing-patterns.md +0 -0
  284. /package/{rules → templates/golang/rules}/golang/ent-orm/SKILL.md +0 -0
  285. /package/{rules → templates/golang/rules}/golang/ent-orm/references/REFERENCE.md +0 -0
  286. /package/{rules → templates/golang/rules}/golang/ent-orm/references/schema-patterns.md +0 -0
  287. /package/{rules → templates/golang/rules}/golang/fiber-framework/SKILL.md +0 -0
  288. /package/{rules → templates/golang/rules}/golang/fiber-framework/references/REFERENCE.md +0 -0
  289. /package/{rules → templates/golang/rules}/golang/fiber-framework/references/routing-patterns.md +0 -0
  290. /package/{rules → templates/golang/rules}/golang/gin-framework/SKILL.md +0 -0
  291. /package/{rules → templates/golang/rules}/golang/gin-framework/references/REFERENCE.md +0 -0
  292. /package/{rules → templates/golang/rules}/golang/gin-framework/references/middleware-patterns.md +0 -0
  293. /package/{rules → templates/golang/rules}/golang/gorm-orm/SKILL.md +0 -0
  294. /package/{rules → templates/golang/rules}/golang/gorm-orm/references/REFERENCE.md +0 -0
  295. /package/{rules → templates/golang/rules}/golang/gorm-orm/references/model-definitions.md +0 -0
  296. /package/{rules → templates/golang/rules}/golang/gorm-orm/references/query-patterns.md +0 -0
  297. /package/{rules → templates/golang/rules}/golang/grpc/SKILL.md +0 -0
  298. /package/{rules → templates/golang/rules}/golang/grpc/references/REFERENCE.md +0 -0
  299. /package/{rules → templates/golang/rules}/golang/grpc/references/service-patterns.md +0 -0
  300. /package/{rules → templates/golang/rules}/golang/testify/SKILL.md +0 -0
  301. /package/{rules → templates/golang/rules}/golang/testify/references/REFERENCE.md +0 -0
  302. /package/{rules → templates/golang/rules}/golang/testify/references/assert-patterns.md +0 -0
  303. /package/{rules → templates/golang/rules}/golang/validator/SKILL.md +0 -0
  304. /package/{rules → templates/golang/rules}/golang/validator/references/REFERENCE.md +0 -0
  305. /package/{rules → templates/golang/rules}/golang/validator/references/validation-tags.md +0 -0
  306. /package/{rules → templates/golang/rules}/golang/viper-config/SKILL.md +0 -0
  307. /package/{rules → templates/golang/rules}/golang/viper-config/references/REFERENCE.md +0 -0
  308. /package/{rules → templates/golang/rules}/golang/viper-config/references/config-loading.md +0 -0
  309. /package/{rules → templates/golang/rules}/golang/wire-di/SKILL.md +0 -0
  310. /package/{rules → templates/golang/rules}/golang/wire-di/references/REFERENCE.md +0 -0
  311. /package/{rules → templates/golang/rules}/golang/wire-di/references/provider-patterns.md +0 -0
  312. /package/{rules → templates/golang/rules}/golang/zap-logging/SKILL.md +0 -0
  313. /package/{rules → templates/golang/rules}/golang/zap-logging/references/REFERENCE.md +0 -0
  314. /package/{rules → templates/golang/rules}/golang/zap-logging/references/logger-config.md +0 -0
  315. /package/{rules → templates/java/rules}/java/build-gradle/SKILL.md +0 -0
  316. /package/{rules → templates/java/rules}/java/build-gradle/references/REFERENCE.md +0 -0
  317. /package/{rules → templates/java/rules}/java/build-gradle/references/kotlin-dsl.md +0 -0
  318. /package/{rules → templates/java/rules}/java/build-gradle/references/task-configuration.md +0 -0
  319. /package/{rules → templates/java/rules}/java/build-maven/SKILL.md +0 -0
  320. /package/{rules → templates/java/rules}/java/build-maven/references/REFERENCE.md +0 -0
  321. /package/{rules → templates/java/rules}/java/build-maven/references/dependency-management.md +0 -0
  322. /package/{rules → templates/java/rules}/java/build-maven/references/lifecycle-phases.md +0 -0
  323. /package/{rules → templates/java/rules}/java/graalvm-native/SKILL.md +0 -0
  324. /package/{rules → templates/java/rules}/java/graalvm-native/references/REFERENCE.md +0 -0
  325. /package/{rules → templates/java/rules}/java/java-collections-streams/SKILL.md +0 -0
  326. /package/{rules → templates/java/rules}/java/java-collections-streams/references/REFERENCE.md +0 -0
  327. /package/{rules → templates/java/rules}/java/java-collections-streams/references/collectors-patterns.md +0 -0
  328. /package/{rules → templates/java/rules}/java/java-collections-streams/references/stream-pipelines.md +0 -0
  329. /package/{rules → templates/java/rules}/java/java-concurrency/SKILL.md +0 -0
  330. /package/{rules → templates/java/rules}/java/java-concurrency/references/REFERENCE.md +0 -0
  331. /package/{rules → templates/java/rules}/java/java-concurrency/references/completable-future.md +0 -0
  332. /package/{rules → templates/java/rules}/java/java-concurrency/references/executor-patterns.md +0 -0
  333. /package/{rules → templates/java/rules}/java/java-concurrency/references/virtual-threads.md +0 -0
  334. /package/{rules → templates/java/rules}/java/java-core-language/SKILL.md +0 -0
  335. /package/{rules → templates/java/rules}/java/java-core-language/references/REFERENCE.md +0 -0
  336. /package/{rules → templates/java/rules}/java/java-core-language/references/jvm-memory-model.md +0 -0
  337. /package/{rules → templates/java/rules}/java/java-core-language/references/modern-java-features.md +0 -0
  338. /package/{rules → templates/java/rules}/java/java-project-structure/SKILL.md +0 -0
  339. /package/{rules → templates/java/rules}/java/java-project-structure/references/REFERENCE.md +0 -0
  340. /package/{rules → templates/java/rules}/java/java-project-structure/references/maven-project-layout.md +0 -0
  341. /package/{rules → templates/java/rules}/java/java-project-structure/references/module-system.md +0 -0
  342. /package/{rules → templates/java/rules}/java/micronaut-core/SKILL.md +0 -0
  343. /package/{rules → templates/java/rules}/java/micronaut-core/references/REFERENCE.md +0 -0
  344. /package/{rules → templates/java/rules}/java/micronaut-reactive/SKILL.md +0 -0
  345. /package/{rules → templates/java/rules}/java/micronaut-reactive/references/REFERENCE.md +0 -0
  346. /package/{rules → templates/java/rules}/java/quarkus-core/SKILL.md +0 -0
  347. /package/{rules → templates/java/rules}/java/quarkus-core/references/REFERENCE.md +0 -0
  348. /package/{rules → templates/java/rules}/java/quarkus-reactive/SKILL.md +0 -0
  349. /package/{rules → templates/java/rules}/java/quarkus-reactive/references/REFERENCE.md +0 -0
  350. /package/{rules → templates/java/rules}/java/spring-batch/SKILL.md +0 -0
  351. /package/{rules → templates/java/rules}/java/spring-batch/references/REFERENCE.md +0 -0
  352. /package/{rules → templates/java/rules}/java/spring-boot-architecture/SKILL.md +0 -0
  353. /package/{rules → templates/java/rules}/java/spring-boot-architecture/references/REFERENCE.md +0 -0
  354. /package/{rules → templates/java/rules}/java/spring-boot-architecture/references/auto-configuration.md +0 -0
  355. /package/{rules → templates/java/rules}/java/spring-boot-architecture/references/configuration-properties.md +0 -0
  356. /package/{rules → templates/java/rules}/java/spring-boot-web/SKILL.md +0 -0
  357. /package/{rules → templates/java/rules}/java/spring-boot-web/references/REFERENCE.md +0 -0
  358. /package/{rules → templates/java/rules}/java/spring-cloud/SKILL.md +0 -0
  359. /package/{rules → templates/java/rules}/java/spring-cloud/references/REFERENCE.md +0 -0
  360. /package/{rules → templates/java/rules}/java/spring-data-jpa/SKILL.md +0 -0
  361. /package/{rules → templates/java/rules}/java/spring-data-jpa/references/REFERENCE.md +0 -0
  362. /package/{rules → templates/java/rules}/java/spring-security/SKILL.md +0 -0
  363. /package/{rules → templates/java/rules}/java/spring-security/references/REFERENCE.md +0 -0
  364. /package/{rules → templates/java/rules}/java/spring-security/references/jwt-auth-flow.md +0 -0
  365. /package/{rules → templates/java/rules}/java/testing-junit-mockito/SKILL.md +0 -0
  366. /package/{rules → templates/java/rules}/java/testing-junit-mockito/references/REFERENCE.md +0 -0
  367. /package/{rules → templates/java/rules}/java/testing-junit-mockito/references/junit5-patterns.md +0 -0
  368. /package/{rules → templates/java/rules}/java/testing-junit-mockito/references/mockito-patterns.md +0 -0
  369. /package/{rules → templates/java/rules}/java/testing-junit-mockito/references/spring-boot-testing.md +0 -0
  370. /package/{rules → templates/javascript/rules}/javascript/best-practices/SKILL.md +0 -0
  371. /package/{rules → templates/javascript/rules}/javascript/best-practices/references/REFERENCE.md +0 -0
  372. /package/{rules → templates/javascript/rules}/javascript/language/SKILL.md +0 -0
  373. /package/{rules → templates/javascript/rules}/javascript/language/references/REFERENCE.md +0 -0
  374. /package/{rules → templates/javascript/rules}/javascript/tooling/SKILL.md +0 -0
  375. /package/{rules → templates/javascript/rules}/javascript/tooling/references/REFERENCE.md +0 -0
  376. /package/{rules → templates/nestjs/rules}/nestjs/api-standards/SKILL.md +0 -0
  377. /package/{rules → templates/nestjs/rules}/nestjs/api-standards/references/pagination-wrapper.md +0 -0
  378. /package/{rules → templates/nestjs/rules}/nestjs/architecture/SKILL.md +0 -0
  379. /package/{rules → templates/nestjs/rules}/nestjs/architecture/references/dynamic-module.md +0 -0
  380. /package/{rules → templates/nestjs/rules}/nestjs/caching/SKILL.md +0 -0
  381. /package/{rules → templates/nestjs/rules}/nestjs/caching/references/REFERENCE.md +0 -0
  382. /package/{rules → templates/nestjs/rules}/nestjs/caching/references/cache-patterns.md +0 -0
  383. /package/{rules → templates/nestjs/rules}/nestjs/configuration/SKILL.md +0 -0
  384. /package/{rules → templates/nestjs/rules}/nestjs/configuration/references/REFERENCE.md +0 -0
  385. /package/{rules → templates/nestjs/rules}/nestjs/configuration/references/config-patterns.md +0 -0
  386. /package/{rules → templates/nestjs/rules}/nestjs/controllers-services/SKILL.md +0 -0
  387. /package/{rules → templates/nestjs/rules}/nestjs/controllers-services/references/REFERENCE.md +0 -0
  388. /package/{rules → templates/nestjs/rules}/nestjs/controllers-services/references/controller-patterns.md +0 -0
  389. /package/{rules → templates/nestjs/rules}/nestjs/controllers-services/references/service-patterns.md +0 -0
  390. /package/{rules → templates/nestjs/rules}/nestjs/database/SKILL.md +0 -0
  391. /package/{rules → templates/nestjs/rules}/nestjs/database/references/REFERENCE.md +0 -0
  392. /package/{rules → templates/nestjs/rules}/nestjs/database/references/typeorm-patterns.md +0 -0
  393. /package/{rules → templates/nestjs/rules}/nestjs/deployment/SKILL.md +0 -0
  394. /package/{rules → templates/nestjs/rules}/nestjs/deployment/references/REFERENCE.md +0 -0
  395. /package/{rules → templates/nestjs/rules}/nestjs/deployment/references/deployment-patterns.md +0 -0
  396. /package/{rules → templates/nestjs/rules}/nestjs/documentation/SKILL.md +0 -0
  397. /package/{rules → templates/nestjs/rules}/nestjs/documentation/references/REFERENCE.md +0 -0
  398. /package/{rules → templates/nestjs/rules}/nestjs/documentation/references/swagger-patterns.md +0 -0
  399. /package/{rules → templates/nestjs/rules}/nestjs/error-handling/SKILL.md +0 -0
  400. /package/{rules → templates/nestjs/rules}/nestjs/error-handling/references/REFERENCE.md +0 -0
  401. /package/{rules → templates/nestjs/rules}/nestjs/error-handling/references/exception-filters.md +0 -0
  402. /package/{rules → templates/nestjs/rules}/nestjs/file-uploads/SKILL.md +0 -0
  403. /package/{rules → templates/nestjs/rules}/nestjs/file-uploads/references/REFERENCE.md +0 -0
  404. /package/{rules → templates/nestjs/rules}/nestjs/file-uploads/references/upload-patterns.md +0 -0
  405. /package/{rules → templates/nestjs/rules}/nestjs/observability/SKILL.md +0 -0
  406. /package/{rules → templates/nestjs/rules}/nestjs/observability/references/REFERENCE.md +0 -0
  407. /package/{rules → templates/nestjs/rules}/nestjs/observability/references/logging-metrics.md +0 -0
  408. /package/{rules → templates/nestjs/rules}/nestjs/performance/SKILL.md +0 -0
  409. /package/{rules → templates/nestjs/rules}/nestjs/performance/references/REFERENCE.md +0 -0
  410. /package/{rules → templates/nestjs/rules}/nestjs/performance/references/performance-patterns.md +0 -0
  411. /package/{rules → templates/nestjs/rules}/nestjs/real-time/SKILL.md +0 -0
  412. /package/{rules → templates/nestjs/rules}/nestjs/real-time/references/REFERENCE.md +0 -0
  413. /package/{rules → templates/nestjs/rules}/nestjs/real-time/references/websocket-patterns.md +0 -0
  414. /package/{rules → templates/nestjs/rules}/nestjs/scheduling/SKILL.md +0 -0
  415. /package/{rules → templates/nestjs/rules}/nestjs/scheduling/references/REFERENCE.md +0 -0
  416. /package/{rules → templates/nestjs/rules}/nestjs/scheduling/references/scheduling-patterns.md +0 -0
  417. /package/{rules → templates/nestjs/rules}/nestjs/search/SKILL.md +0 -0
  418. /package/{rules → templates/nestjs/rules}/nestjs/search/references/REFERENCE.md +0 -0
  419. /package/{rules → templates/nestjs/rules}/nestjs/search/references/search-patterns.md +0 -0
  420. /package/{rules → templates/nestjs/rules}/nestjs/security/SKILL.md +0 -0
  421. /package/{rules → templates/nestjs/rules}/nestjs/security/references/REFERENCE.md +0 -0
  422. /package/{rules → templates/nestjs/rules}/nestjs/security/references/authentication.md +0 -0
  423. /package/{rules → templates/nestjs/rules}/nestjs/testing/SKILL.md +0 -0
  424. /package/{rules → templates/nestjs/rules}/nestjs/testing/references/REFERENCE.md +0 -0
  425. /package/{rules → templates/nestjs/rules}/nestjs/testing/references/unit-testing.md +0 -0
  426. /package/{rules → templates/nestjs/rules}/nestjs/transport/SKILL.md +0 -0
  427. /package/{rules → templates/nestjs/rules}/nestjs/transport/references/REFERENCE.md +0 -0
  428. /package/{rules → templates/nestjs/rules}/nestjs/transport/references/microservices-patterns.md +0 -0
  429. /package/{rules → templates/nextjs/rules}/nextjs/app-router/SKILL.md +0 -0
  430. /package/{rules → templates/nextjs/rules}/nextjs/app-router/references/REFERENCE.md +0 -0
  431. /package/{rules → templates/nextjs/rules}/nextjs/app-router/references/routing-patterns.md +0 -0
  432. /package/{rules → templates/nextjs/rules}/nextjs/architecture/SKILL.md +0 -0
  433. /package/{rules → templates/nextjs/rules}/nextjs/architecture/references/fsd-structure.md +0 -0
  434. /package/{rules → templates/nextjs/rules}/nextjs/authentication/SKILL.md +0 -0
  435. /package/{rules → templates/nextjs/rules}/nextjs/authentication/references/auth-implementation.md +0 -0
  436. /package/{rules → templates/nextjs/rules}/nextjs/caching/SKILL.md +0 -0
  437. /package/{rules → templates/nextjs/rules}/nextjs/caching/references/REFERENCE.md +0 -0
  438. /package/{rules → templates/nextjs/rules}/nextjs/caching/references/cache-strategies.md +0 -0
  439. /package/{rules → templates/nextjs/rules}/nextjs/data-access-layer/SKILL.md +0 -0
  440. /package/{rules → templates/nextjs/rules}/nextjs/data-access-layer/references/patterns.md +0 -0
  441. /package/{rules → templates/nextjs/rules}/nextjs/data-fetching/SKILL.md +0 -0
  442. /package/{rules → templates/nextjs/rules}/nextjs/data-fetching/references/REFERENCE.md +0 -0
  443. /package/{rules → templates/nextjs/rules}/nextjs/data-fetching/references/fetch-patterns.md +0 -0
  444. /package/{rules → templates/nextjs/rules}/nextjs/internationalization/SKILL.md +0 -0
  445. /package/{rules → templates/nextjs/rules}/nextjs/internationalization/references/REFERENCE.md +0 -0
  446. /package/{rules → templates/nextjs/rules}/nextjs/internationalization/references/i18n-patterns.md +0 -0
  447. /package/{rules → templates/nextjs/rules}/nextjs/optimization/SKILL.md +0 -0
  448. /package/{rules → templates/nextjs/rules}/nextjs/optimization/references/REFERENCE.md +0 -0
  449. /package/{rules → templates/nextjs/rules}/nextjs/optimization/references/optimization-patterns.md +0 -0
  450. /package/{rules → templates/nextjs/rules}/nextjs/rendering/SKILL.md +0 -0
  451. /package/{rules → templates/nextjs/rules}/nextjs/rendering/references/REFERENCE.md +0 -0
  452. /package/{rules → templates/nextjs/rules}/nextjs/rendering/references/rendering-modes.md +0 -0
  453. /package/{rules → templates/nextjs/rules}/nextjs/server-actions/SKILL.md +0 -0
  454. /package/{rules → templates/nextjs/rules}/nextjs/server-actions/references/REFERENCE.md +0 -0
  455. /package/{rules → templates/nextjs/rules}/nextjs/server-actions/references/action-patterns.md +0 -0
  456. /package/{rules → templates/nextjs/rules}/nextjs/server-components/SKILL.md +0 -0
  457. /package/{rules → templates/nextjs/rules}/nextjs/server-components/references/REFERENCE.md +0 -0
  458. /package/{rules → templates/nextjs/rules}/nextjs/server-components/references/component-patterns.md +0 -0
  459. /package/{rules → templates/nextjs/rules}/nextjs/state-management/SKILL.md +0 -0
  460. /package/{rules → templates/nextjs/rules}/nextjs/state-management/references/REFERENCE.md +0 -0
  461. /package/{rules → templates/nextjs/rules}/nextjs/state-management/references/state-patterns.md +0 -0
  462. /package/{rules → templates/nextjs/rules}/nextjs/styling/SKILL.md +0 -0
  463. /package/{rules → templates/nextjs/rules}/nextjs/styling/references/implementation.md +0 -0
  464. /package/{rules → templates/react/rules}/react/component-patterns/SKILL.md +0 -0
  465. /package/{rules → templates/react/rules}/react/component-patterns/references/REFERENCE.md +0 -0
  466. /package/{rules → templates/react/rules}/react/hooks/SKILL.md +0 -0
  467. /package/{rules → templates/react/rules}/react/hooks/references/REFERENCE.md +0 -0
  468. /package/{rules → templates/react/rules}/react/hooks.rule.md +0 -0
  469. /package/{rules → templates/react/rules}/react/performance/SKILL.md +0 -0
  470. /package/{rules → templates/react/rules}/react/performance/references/REFERENCE.md +0 -0
  471. /package/{rules → templates/react/rules}/react/security/SKILL.md +0 -0
  472. /package/{rules → templates/react/rules}/react/security/references/REFERENCE.md +0 -0
  473. /package/{rules → templates/react/rules}/react/state-management/SKILL.md +0 -0
  474. /package/{rules → templates/react/rules}/react/state-management/references/REFERENCE.md +0 -0
  475. /package/{rules → templates/react/rules}/react/testing/SKILL.md +0 -0
  476. /package/{rules → templates/react/rules}/react/testing/references/REFERENCE.md +0 -0
  477. /package/{rules → templates/react/rules}/react/tooling/SKILL.md +0 -0
  478. /package/{rules → templates/react/rules}/react/typescript/SKILL.md +0 -0
  479. /package/{rules → templates/rust/rules}/rust/actix-web/SKILL.md +0 -0
  480. /package/{rules → templates/rust/rules}/rust/actix-web/references/REFERENCE.md +0 -0
  481. /package/{rules → templates/rust/rules}/rust/actix-web/references/handler-patterns.md +0 -0
  482. /package/{rules → templates/rust/rules}/rust/async-graphql/SKILL.md +0 -0
  483. /package/{rules → templates/rust/rules}/rust/async-graphql/references/REFERENCE.md +0 -0
  484. /package/{rules → templates/rust/rules}/rust/async-graphql/references/schema-patterns.md +0 -0
  485. /package/{rules → templates/rust/rules}/rust/axum/SKILL.md +0 -0
  486. /package/{rules → templates/rust/rules}/rust/axum/references/REFERENCE.md +0 -0
  487. /package/{rules → templates/rust/rules}/rust/axum/references/handler-patterns.md +0 -0
  488. /package/{rules → templates/rust/rules}/rust/bevy/SKILL.md +0 -0
  489. /package/{rules → templates/rust/rules}/rust/bevy/references/REFERENCE.md +0 -0
  490. /package/{rules → templates/rust/rules}/rust/bevy/references/ecs-patterns.md +0 -0
  491. /package/{rules → templates/rust/rules}/rust/clap/SKILL.md +0 -0
  492. /package/{rules → templates/rust/rules}/rust/clap/references/REFERENCE.md +0 -0
  493. /package/{rules → templates/rust/rules}/rust/clap/references/derive-patterns.md +0 -0
  494. /package/{rules → templates/rust/rules}/rust/core/SKILL.md +0 -0
  495. /package/{rules → templates/rust/rules}/rust/core/references/REFERENCE.md +0 -0
  496. /package/{rules → templates/rust/rules}/rust/core/references/error-handling.md +0 -0
  497. /package/{rules → templates/rust/rules}/rust/diesel-orm/SKILL.md +0 -0
  498. /package/{rules → templates/rust/rules}/rust/diesel-orm/references/REFERENCE.md +0 -0
  499. /package/{rules → templates/rust/rules}/rust/diesel-orm/references/schema-patterns.md +0 -0
  500. /package/{rules → templates/rust/rules}/rust/rocket/SKILL.md +0 -0
  501. /package/{rules → templates/rust/rules}/rust/rocket/references/REFERENCE.md +0 -0
  502. /package/{rules → templates/rust/rules}/rust/rocket/references/handler-patterns.md +0 -0
  503. /package/{rules → templates/rust/rules}/rust/sea-orm/SKILL.md +0 -0
  504. /package/{rules → templates/rust/rules}/rust/sea-orm/references/REFERENCE.md +0 -0
  505. /package/{rules → templates/rust/rules}/rust/sea-orm/references/entity-patterns.md +0 -0
  506. /package/{rules → templates/rust/rules}/rust/serde-serialization/SKILL.md +0 -0
  507. /package/{rules → templates/rust/rules}/rust/serde-serialization/references/REFERENCE.md +0 -0
  508. /package/{rules → templates/rust/rules}/rust/serde-serialization/references/serialization-patterns.md +0 -0
  509. /package/{rules → templates/rust/rules}/rust/sqlx-database/SKILL.md +0 -0
  510. /package/{rules → templates/rust/rules}/rust/sqlx-database/references/REFERENCE.md +0 -0
  511. /package/{rules → templates/rust/rules}/rust/sqlx-database/references/query-patterns.md +0 -0
  512. /package/{rules → templates/rust/rules}/rust/tauri/SKILL.md +0 -0
  513. /package/{rules → templates/rust/rules}/rust/tauri/references/REFERENCE.md +0 -0
  514. /package/{rules → templates/rust/rules}/rust/tauri/references/command-patterns.md +0 -0
  515. /package/{rules → templates/rust/rules}/rust/tokio-runtime/SKILL.md +0 -0
  516. /package/{rules → templates/rust/rules}/rust/tokio-runtime/references/REFERENCE.md +0 -0
  517. /package/{rules → templates/rust/rules}/rust/tokio-runtime/references/async-patterns.md +0 -0
  518. /package/{rules → templates/rust/rules}/rust/tokio-runtime/references/synchronization.md +0 -0
  519. /package/{rules → templates/rust/rules}/rust/tonic/SKILL.md +0 -0
  520. /package/{rules → templates/rust/rules}/rust/tonic/references/REFERENCE.md +0 -0
  521. /package/{rules → templates/rust/rules}/rust/tonic/references/service-patterns.md +0 -0
  522. /package/{rules → templates/rust/rules}/rust/tracing/SKILL.md +0 -0
  523. /package/{rules → templates/rust/rules}/rust/tracing/references/REFERENCE.md +0 -0
  524. /package/{rules → templates/rust/rules}/rust/tracing/references/instrumentation.md +0 -0
  525. /package/{rules → templates/typescript/rules}/typescript/best-practices/SKILL.md +0 -0
  526. /package/{rules → templates/typescript/rules}/typescript/best-practices/references/REFERENCE.md +0 -0
  527. /package/{rules → templates/typescript/rules}/typescript/language/SKILL.md +0 -0
  528. /package/{rules → templates/typescript/rules}/typescript/language/references/REFERENCE.md +0 -0
  529. /package/{rules → templates/typescript/rules}/typescript/patterns.rule.md +0 -0
  530. /package/{rules → templates/typescript/rules}/typescript/security/SKILL.md +0 -0
  531. /package/{rules → templates/typescript/rules}/typescript/security/references/REFERENCE.md +0 -0
  532. /package/{rules → templates/typescript/rules}/typescript/tooling/SKILL.md +0 -0
  533. /package/{rules → templates/typescript/rules}/typescript/tooling/references/REFERENCE.md +0 -0
package/statusline.cjs DELETED
@@ -1,500 +0,0 @@
1
- #!/usr/bin/env node
2
- 'use strict';
3
-
4
- /**
5
- * Custom Claude Code statusline for Node.js - Multi-line Edition
6
- * Cross-platform support: Windows, macOS, Linux
7
- * Features: ANSI colors, tool/agent/todo tracking, context window, session timer
8
- * No external dependencies - uses only Node.js built-in modules
9
- */
10
-
11
- const { stdin, env } = require('process');
12
- const { execSync } = require('child_process');
13
- const os = require('os');
14
- const fs = require('fs');
15
- const path = require('path');
16
-
17
- // Import modular components
18
- const { green, yellow, red, cyan, magenta, dim, coloredBar, RESET, shouldUseColor } = require('./hooks/lib/colors.cjs');
19
- const { parseTranscript } = require('./hooks/lib/transcript-parser.cjs');
20
- const { countConfigs } = require('./hooks/lib/config-counter.cjs');
21
-
22
- // Buffer constant matching /context output (22.5% of 200k)
23
- const AUTOCOMPACT_BUFFER = 45000;
24
-
25
- /**
26
- * Safe command execution wrapper
27
- */
28
- function exec(cmd) {
29
- try {
30
- return execSync(cmd, {
31
- encoding: 'utf8',
32
- stdio: ['pipe', 'pipe', 'ignore'],
33
- windowsHide: true
34
- }).trim();
35
- } catch {
36
- return '';
37
- }
38
- }
39
-
40
- /**
41
- * Expand home directory to ~
42
- */
43
- function expandHome(filePath) {
44
- const homeDir = os.homedir();
45
- return filePath.startsWith(homeDir) ? filePath.replace(homeDir, '~') : filePath;
46
- }
47
-
48
- /**
49
- * Get terminal width with fallback chain
50
- * Piped context (statusline) needs alternative detection
51
- */
52
- function getTerminalWidth() {
53
- // Try multiple sources - stderr might still be TTY even when stdout is piped
54
- if (process.stderr.columns) return process.stderr.columns;
55
- if (env.COLUMNS) {
56
- const parsed = parseInt(env.COLUMNS, 10);
57
- if (!isNaN(parsed) && parsed > 0) return parsed;
58
- }
59
- // Subprocess fallback
60
- const tputCols = exec('tput cols');
61
- if (tputCols && /^\d+$/.test(tputCols)) return parseInt(tputCols, 10);
62
- return 120; // Safe default
63
- }
64
-
65
- /**
66
- * Calculate visible string length (strip ANSI codes, account for emoji width)
67
- * Emojis typically render as 2 columns in terminals
68
- */
69
- function visibleLength(str) {
70
- if (!str || typeof str !== 'string') return 0;
71
- // Strip ANSI escape codes
72
- const noAnsi = str.replace(/\x1b\[[0-9;]*m/g, '');
73
- // Count emojis (they render as ~2 cols) - common emoji ranges
74
- const emojiMatches = noAnsi.match(/[\u{1F300}-\u{1F9FF}\u{2600}-\u{26FF}\u{2700}-\u{27BF}]/gu) || [];
75
- return noAnsi.length + emojiMatches.length; // +1 per emoji (base length + 1 = 2 cols)
76
- }
77
-
78
- /**
79
- * Format elapsed time from start to end (or now)
80
- */
81
- function formatElapsed(startTime, endTime) {
82
- if (!startTime) return '0s';
83
- const start = startTime instanceof Date ? startTime.getTime() : new Date(startTime).getTime();
84
- if (isNaN(start)) return '0s';
85
- const end = endTime ? (endTime instanceof Date ? endTime.getTime() : new Date(endTime).getTime()) : Date.now();
86
- if (isNaN(end)) return '0s';
87
- const ms = end - start;
88
- if (ms < 0 || ms < 1000) return '<1s';
89
- if (ms < 60000) return `${Math.round(ms / 1000)}s`;
90
- const mins = Math.floor(ms / 60000);
91
- const secs = Math.round((ms % 60000) / 1000);
92
- return `${mins}m ${secs}s`;
93
- }
94
-
95
- /**
96
- * Read stdin asynchronously
97
- */
98
- async function readStdin() {
99
- return new Promise((resolve, reject) => {
100
- const chunks = [];
101
- stdin.setEncoding('utf8');
102
- stdin.on('data', chunk => chunks.push(chunk));
103
- stdin.on('end', () => resolve(chunks.join('')));
104
- stdin.on('error', reject);
105
- });
106
- }
107
-
108
- // ============================================================================
109
- // LINE RENDERERS
110
- // ============================================================================
111
-
112
- /**
113
- * Render session lines with multi-level responsive wrapping
114
- * Combines parts based on content length vs terminal width
115
- * Tries to minimize lines while keeping content readable
116
- */
117
- function renderSessionLines(ctx) {
118
- const lines = [];
119
- const termWidth = getTerminalWidth();
120
- const threshold = Math.floor(termWidth * 0.85);
121
-
122
- // Build all atomic parts for flexible composition (no colors on static text)
123
- const dirPart = `📁 ${ctx.currentDir}`;
124
-
125
- let branchPart = '';
126
- if (ctx.gitBranch) {
127
- branchPart = `🌿 ${ctx.gitBranch}`;
128
- // Build git status indicators: (unstaged, +staged, ahead↑, behind↓)
129
- const gitIndicators = [];
130
- if (ctx.gitUnstaged > 0) gitIndicators.push(`${ctx.gitUnstaged}`);
131
- if (ctx.gitStaged > 0) gitIndicators.push(`+${ctx.gitStaged}`);
132
- if (ctx.gitAhead > 0) gitIndicators.push(`${ctx.gitAhead}↑`);
133
- if (ctx.gitBehind > 0) gitIndicators.push(`${ctx.gitBehind}↓`);
134
- if (gitIndicators.length > 0) {
135
- branchPart += ` ${yellow(`(${gitIndicators.join(', ')})`)}`;
136
- }
137
- }
138
-
139
- // Active plan indicator (disabled for now - code preserved)
140
- // const planPart = ctx.activePlan ? `📋 ${ctx.activePlan}` : '';
141
- const planPart = '';
142
-
143
- // Combined location (dir + branch + plan)
144
- let locationPart = branchPart ? `${dirPart} ${branchPart}` : dirPart;
145
- if (planPart) locationPart += ` ${planPart}`;
146
-
147
- // Build session part: 🤖 model contextBar% ⌛ time left (usage%)
148
- let sessionPart = `🤖 ${ctx.modelName}`;
149
- if (ctx.contextPercent > 0) {
150
- sessionPart += ` ${coloredBar(ctx.contextPercent, 12)} ${ctx.contextPercent}%`;
151
- }
152
- // Add usage/reset info to session part (stays on line 1 with model - Claude Code only reads line 1)
153
- if (ctx.sessionText) {
154
- let usageStr = `⌛ ${ctx.sessionText.replace(' until reset', ' left')}`;
155
- if (ctx.usagePercent != null) usageStr += ` (${Math.round(ctx.usagePercent)}% used)`;
156
- sessionPart += ` ${usageStr}`;
157
- }
158
-
159
- // Build stats part (only lines changed now)
160
- const statsItems = [];
161
- // if (ctx.costText) statsItems.push(`💵 ${ctx.costText.replace(/(\.\d{2})\d+/, '$1')}`);
162
- if (ctx.linesAdded > 0 || ctx.linesRemoved > 0) {
163
- statsItems.push(`📝 ${green(`+${ctx.linesAdded}`)} ${red(`-${ctx.linesRemoved}`)}`);
164
- }
165
- const statsPart = statsItems.join(' ');
166
-
167
- // Calculate lengths for layout decisions
168
- const locationLen = visibleLength(locationPart);
169
- const sessionLen = visibleLength(sessionPart);
170
- const statsLen = visibleLength(statsPart);
171
-
172
- // Layout priority: SESSION FIRST (Claude Code only reads line 1)
173
- // Line 1: model + context + usage (most important for Claude Code)
174
- // Line 2+: location, git, stats
175
- const allOneLine = `${sessionPart} ${locationPart} ${statsPart}`;
176
- const sessionLocation = `${sessionPart} ${locationPart}`;
177
- const sessionStats = `${sessionPart} ${statsPart}`;
178
-
179
- if (visibleLength(allOneLine) <= threshold && statsLen > 0) {
180
- // Ultra-wide: everything on one line (session first)
181
- lines.push(allOneLine);
182
- } else if (visibleLength(sessionLocation) <= threshold) {
183
- // Wide: session+location on line 1 | stats on line 2
184
- lines.push(sessionLocation);
185
- if (statsLen > 0) lines.push(statsPart);
186
- } else if (sessionLen <= threshold) {
187
- // Medium: session on line 1 | location on line 2 | stats on line 3
188
- lines.push(sessionPart);
189
- lines.push(locationPart);
190
- if (statsLen > 0) lines.push(statsPart);
191
- } else {
192
- // Narrow: session | dir | branch | stats (each on own line)
193
- lines.push(sessionPart);
194
- lines.push(dirPart);
195
- if (branchPart) lines.push(branchPart);
196
- if (planPart) lines.push(planPart);
197
- if (statsLen > 0) lines.push(statsPart);
198
- }
199
-
200
- return lines;
201
- }
202
-
203
- /**
204
- * Safe date parsing - returns epoch ms or 0 for invalid dates
205
- */
206
- function safeGetTime(dateValue) {
207
- if (!dateValue) return 0;
208
- const time = new Date(dateValue).getTime();
209
- return isNaN(time) ? 0 : time;
210
- }
211
-
212
- /**
213
- * Render agents lines as compact chronological flow with duplicate collapsing
214
- * Format: ○ type ×N → ● type (N done)
215
- * ▸ description (elapsed)
216
- * @returns {string[]} Array of lines (flow line + optional task line)
217
- */
218
- function renderAgentsLines(transcript) {
219
- const { agents } = transcript;
220
- if (!agents || agents.length === 0) return [];
221
-
222
- const running = agents.filter(a => a.status === 'running');
223
- const completed = agents.filter(a => a.status === 'completed');
224
-
225
- // Sort all by startTime (safe NaN handling)
226
- const allAgents = [...running, ...completed];
227
- allAgents.sort((a, b) => safeGetTime(a.startTime) - safeGetTime(b.startTime));
228
-
229
- if (allAgents.length === 0) return [];
230
-
231
- // Collapse consecutive duplicate types FIRST (before slicing)
232
- const collapsed = [];
233
- for (const agent of allAgents) {
234
- const type = agent.type || 'agent'; // fallback for missing type
235
- const last = collapsed[collapsed.length - 1];
236
- if (last && last.type === type && last.status === agent.status) {
237
- last.count++;
238
- last.agents.push(agent);
239
- } else {
240
- collapsed.push({ type, status: agent.status, count: 1, agents: [agent] });
241
- }
242
- }
243
-
244
- // THEN slice to show last 4 collapsed groups
245
- const toShow = collapsed.slice(-4);
246
-
247
- // Build compact flow line with dots and ×N for duplicates
248
- const flowParts = toShow.map(group => {
249
- const icon = group.status === 'running' ? yellow('●') : dim('○');
250
- const suffix = group.count > 1 ? ` ×${group.count}` : '';
251
- return `${icon} ${group.type}${suffix}`;
252
- });
253
-
254
- const lines = [];
255
- const completedCount = agents.filter(a => a.status === 'completed').length;
256
- const flowSuffix = completedCount > 2 ? ` ${dim(`(${completedCount} done)`)}` : '';
257
- lines.push(flowParts.join(' → ') + flowSuffix);
258
-
259
- // Add indented task description for running agent, or last completed if none running
260
- const runningAgent = running[0];
261
- const lastCompleted = completed[completed.length - 1];
262
- const detailAgent = runningAgent || lastCompleted;
263
-
264
- if (detailAgent && detailAgent.description) {
265
- const desc = detailAgent.description.length > 50
266
- ? detailAgent.description.slice(0, 47) + '...'
267
- : detailAgent.description;
268
- const elapsed = formatElapsed(detailAgent.startTime, detailAgent.endTime);
269
- const icon = detailAgent.status === 'running' ? yellow('▸') : dim('▸');
270
- lines.push(` ${icon} ${desc} ${dim(`(${elapsed})`)}`);
271
- }
272
-
273
- return lines;
274
- }
275
-
276
- /**
277
- * Render todos line (if todos exist)
278
- * In-progress task with activeForm + detailed progress (done/pending)
279
- */
280
- function renderTodosLine(transcript) {
281
- const { todos } = transcript;
282
- if (!todos || todos.length === 0) return null;
283
-
284
- const inProgress = todos.find(t => t.status === 'in_progress');
285
- const completedCount = todos.filter(t => t.status === 'completed').length;
286
- const pendingCount = todos.filter(t => t.status === 'pending').length;
287
- const total = todos.length;
288
-
289
- if (!inProgress) {
290
- if (completedCount === total && total > 0) {
291
- return `${green('✓')} All ${total} todos complete`;
292
- }
293
- // Show pending if no in_progress
294
- if (pendingCount > 0) {
295
- const nextPending = todos.find(t => t.status === 'pending');
296
- const nextTask = nextPending?.content || 'Next task';
297
- const display = nextTask.length > 40 ? nextTask.slice(0, 37) + '...' : nextTask;
298
- return `${dim('○')} Next: ${display} ${dim(`(${completedCount} done, ${pendingCount} pending)`)}`;
299
- }
300
- return null;
301
- }
302
-
303
- // Show activeForm (present continuous) if available, else content
304
- const displayText = inProgress.activeForm || inProgress.content;
305
- const display = displayText.length > 50 ? displayText.slice(0, 47) + '...' : displayText;
306
- return `${yellow('▸')} ${display} ${dim(`(${completedCount} done, ${pendingCount} pending)`)}`;
307
- }
308
-
309
- /**
310
- * Main render function - outputs all lines
311
- * Falls back to single line if multi-line fails
312
- */
313
- function render(ctx, singleLineMode = false) {
314
- const lines = [];
315
-
316
- // Session lines (cleaner multi-line layout)
317
- const sessionLines = renderSessionLines(ctx);
318
- lines.push(...sessionLines);
319
-
320
- if (!singleLineMode) {
321
- // Agents lines (one per agent for clarity)
322
- const agentsLines = renderAgentsLines(ctx.transcript);
323
- lines.push(...agentsLines);
324
-
325
- // Todos line (if exist)
326
- const todosLine = renderTodosLine(ctx.transcript);
327
- if (todosLine) lines.push(todosLine);
328
- }
329
-
330
- // Output all lines with non-breaking spaces for alignment
331
- for (const line of lines) {
332
- const outputLine = shouldUseColor ? `${RESET}${line.replace(/ /g, '\u00A0')}` : line;
333
- console.log(outputLine);
334
- }
335
- }
336
-
337
- // ============================================================================
338
- // MAIN
339
- // ============================================================================
340
-
341
- async function main() {
342
- try {
343
- const input = await readStdin();
344
- if (!input.trim()) {
345
- console.error('No input provided');
346
- process.exit(1);
347
- }
348
-
349
- const data = JSON.parse(input);
350
-
351
- // Extract basic information
352
- let currentDir = data.workspace?.current_dir || data.cwd || 'unknown';
353
- currentDir = expandHome(currentDir);
354
-
355
- const modelName = data.model?.display_name || 'Claude';
356
-
357
- // Git detection
358
- let gitBranch = '';
359
- let gitUnstaged = 0;
360
- let gitStaged = 0;
361
- let gitAhead = 0;
362
- let gitBehind = 0;
363
- if (exec('git rev-parse --git-dir')) {
364
- gitBranch = exec('git branch --show-current') || exec('git rev-parse --short HEAD');
365
- const unstagedOutput = exec('git diff --name-only');
366
- if (unstagedOutput) gitUnstaged = unstagedOutput.split('\n').filter(l => l.trim()).length;
367
- // Staged files count
368
- const stagedOutput = exec('git diff --cached --name-only');
369
- if (stagedOutput) gitStaged = stagedOutput.split('\n').filter(l => l.trim()).length;
370
- // Ahead/behind upstream
371
- const aheadBehind = exec('git rev-list --left-right --count @{u}...HEAD 2>/dev/null');
372
- if (aheadBehind) {
373
- const parts = aheadBehind.split(/\s+/);
374
- gitBehind = parseInt(parts[0], 10) || 0;
375
- gitAhead = parseInt(parts[1], 10) || 0;
376
- }
377
- }
378
-
379
- // Active plan detection - read from session temp file
380
- let activePlan = '';
381
- try {
382
- const sessionId = data.session_id;
383
- if (sessionId) {
384
- const sessionPath = path.join(os.tmpdir(), `ck-session-${sessionId}.json`);
385
- if (fs.existsSync(sessionPath)) {
386
- const session = JSON.parse(fs.readFileSync(sessionPath, 'utf8'));
387
- const planPath = session.activePlan?.trim();
388
- if (planPath) {
389
- // Extract slug from path like "plans/260106-1554-statusline-visual"
390
- const match = planPath.match(/plans\/\d+-\d+-(.+?)(?:\/|$)/);
391
- activePlan = match ? match[1] : planPath.split('/').pop();
392
- }
393
- }
394
- }
395
- } catch {}
396
-
397
- // Context window - use current_usage fields with AUTOCOMPACT_BUFFER
398
- const usage = data.context_window?.current_usage || {};
399
- const contextSize = data.context_window?.context_window_size || 0;
400
- let contextPercent = 0;
401
- let totalTokens = 0;
402
-
403
- if (contextSize > 0 && contextSize > AUTOCOMPACT_BUFFER) {
404
- totalTokens = (usage.input_tokens ?? 0) +
405
- (usage.cache_creation_input_tokens ?? 0) +
406
- (usage.cache_read_input_tokens ?? 0);
407
-
408
- // Add buffer to match /context calculation
409
- contextPercent = Math.min(100, Math.round(((totalTokens + AUTOCOMPACT_BUFFER) / contextSize) * 100));
410
- }
411
-
412
- // Write context data to temp file for hooks to read
413
- const sessionId = data.session_id;
414
- if (sessionId && contextSize > 0) {
415
- try {
416
- const contextDataPath = path.join(os.tmpdir(), `ck-context-${sessionId}.json`);
417
- fs.writeFileSync(contextDataPath, JSON.stringify({
418
- percent: contextPercent,
419
- tokens: totalTokens,
420
- size: contextSize,
421
- usage: usage,
422
- timestamp: Date.now()
423
- }));
424
- } catch {}
425
- }
426
-
427
- // Session timer - read actual reset time from usage limits cache
428
- let sessionText = '';
429
- const transcriptPath = data.transcript_path;
430
-
431
- // Parse transcript for tools/agents/todos
432
- const transcript = transcriptPath ? await parseTranscript(transcriptPath) : { tools: [], agents: [], todos: [], sessionStart: null };
433
-
434
- // Read actual reset time and utilization from usage limits cache (written by usage-context-awareness hook)
435
- let usagePercent = null;
436
- try {
437
- const usageCachePath = path.join(os.tmpdir(), 'ck-usage-limits-cache.json');
438
- if (fs.existsSync(usageCachePath)) {
439
- const cache = JSON.parse(fs.readFileSync(usageCachePath, 'utf8'));
440
- const fiveHour = cache.data?.five_hour;
441
- usagePercent = fiveHour?.utilization ?? null;
442
- const resetAt = fiveHour?.resets_at;
443
- if (resetAt) {
444
- const resetTime = new Date(resetAt);
445
- const remaining = Math.floor(resetTime.getTime() / 1000) - Math.floor(Date.now() / 1000);
446
- if (remaining > 0 && remaining < 18000) {
447
- const rh = Math.floor(remaining / 3600);
448
- const rm = Math.floor((remaining % 3600) / 60);
449
- sessionText = `${rh}h ${rm}m until reset`;
450
- }
451
- }
452
- }
453
- } catch {}
454
-
455
- // Cost and lines changed
456
- const billingMode = env.CLAUDE_BILLING_MODE || 'api';
457
- const costUSD = data.cost?.total_cost_usd;
458
- const costText = billingMode === 'api' && costUSD && /^\d+(\.\d+)?$/.test(String(costUSD))
459
- ? `$${parseFloat(costUSD).toFixed(4)}`
460
- : null;
461
- const linesAdded = data.cost?.total_lines_added || 0;
462
- const linesRemoved = data.cost?.total_lines_removed || 0;
463
-
464
- // Config counts
465
- const rawDir = data.workspace?.current_dir || data.cwd || process.cwd();
466
- const configs = countConfigs(rawDir);
467
-
468
- // Build render context
469
- const ctx = {
470
- modelName,
471
- currentDir,
472
- gitBranch,
473
- gitUnstaged,
474
- gitStaged,
475
- gitAhead,
476
- gitBehind,
477
- activePlan,
478
- contextPercent,
479
- sessionText,
480
- usagePercent,
481
- costText,
482
- linesAdded,
483
- linesRemoved,
484
- configs,
485
- transcript
486
- };
487
-
488
- // Render (multi-line by default)
489
- render(ctx, false);
490
-
491
- } catch (err) {
492
- // Fallback: output minimal single line on any error
493
- console.log('📁 ' + (process.cwd() || 'unknown'));
494
- }
495
- }
496
-
497
- main().catch(() => {
498
- console.log('📁 error');
499
- process.exit(1);
500
- });