@punks/cli 2.6.1 → 3.0.0-beta.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 (102) hide show
  1. package/AGENTS.md +1 -1
  2. package/README.md +42 -24
  3. package/dist/BASELINE_CHANGELOG.md +57 -0
  4. package/dist/CHANGELOG.md +80 -0
  5. package/dist/data/scripts/harness-projection/adapters/claude.d.mts +3 -0
  6. package/dist/data/scripts/harness-projection/adapters/claude.mjs +124 -0
  7. package/dist/data/scripts/harness-projection/adapters/codex.d.mts +3 -0
  8. package/dist/data/scripts/harness-projection/adapters/codex.mjs +137 -0
  9. package/dist/data/scripts/harness-projection/adapters/cursor.d.mts +5 -0
  10. package/dist/data/scripts/harness-projection/adapters/cursor.mjs +106 -0
  11. package/dist/data/scripts/harness-projection/adapters/opencode.d.mts +5 -0
  12. package/dist/data/scripts/harness-projection/adapters/opencode.mjs +100 -0
  13. package/dist/data/scripts/harness-projection/apply.d.mts +12 -0
  14. package/dist/data/scripts/harness-projection/apply.mjs +96 -0
  15. package/dist/data/scripts/harness-projection/core.d.mts +8 -0
  16. package/dist/data/scripts/harness-projection/core.mjs +239 -0
  17. package/dist/data/scripts/harness-projection/test-fixtures/application-context-plan.json +27 -0
  18. package/dist/data/scripts/harness-projection/test-fixtures/claude/actions.json +109 -0
  19. package/dist/data/scripts/harness-projection/test-fixtures/claude/context-plan.json +150 -0
  20. package/dist/data/scripts/harness-projection/test-fixtures/claude/matrix.json +23 -0
  21. package/dist/data/scripts/harness-projection/test-fixtures/claude/traces.json +15 -0
  22. package/dist/data/scripts/harness-projection/test-fixtures/codex/actions.json +124 -0
  23. package/dist/data/scripts/harness-projection/test-fixtures/codex/context-plan.json +150 -0
  24. package/dist/data/scripts/harness-projection/test-fixtures/codex/matrix.json +23 -0
  25. package/dist/data/scripts/harness-projection/test-fixtures/codex/traces.json +15 -0
  26. package/dist/data/scripts/harness-projection/test-fixtures/cursor/compiler-input.json +93 -0
  27. package/dist/data/scripts/harness-projection/test-fixtures/cursor/context-plan.json +108 -0
  28. package/dist/data/scripts/harness-projection/test-fixtures/cursor/matrix.json +19 -0
  29. package/dist/data/scripts/harness-projection/test-fixtures/cursor/projection.json +54 -0
  30. package/dist/data/scripts/harness-projection/test-fixtures/mixed-context-plan.json +35 -0
  31. package/dist/data/scripts/harness-projection/test-fixtures/opencode/compiler-input.json +93 -0
  32. package/dist/data/scripts/harness-projection/test-fixtures/opencode/context-plan.json +108 -0
  33. package/dist/data/scripts/harness-projection/test-fixtures/opencode/matrix.json +19 -0
  34. package/dist/data/scripts/harness-projection/test-fixtures/opencode/projection.json +51 -0
  35. package/dist/data/scripts/sync-subagents.mjs +1113 -33
  36. package/dist/data/subagents/manifest.mjs +5 -6
  37. package/dist/index.js +1373 -62672
  38. package/dist/skills/agnostic/docs/docs-onboarding/SKILL.md +1 -1
  39. package/dist/skills/agnostic/docs/docs-onboarding/references/artifact-contract.md +2 -2
  40. package/dist/skills/agnostic/planning/create-plan/SKILL.md +11 -10
  41. package/dist/skills/agnostic/planning/create-plan/references/grill-ambiguity.md +10 -31
  42. package/dist/skills/agnostic/planning/create-plan/references/plan-schema.md +2 -2
  43. package/dist/skills/agnostic/planning/create-spec/SKILL.md +3 -5
  44. package/dist/skills/agnostic/planning/create-spec/assets/SPEC-TEMPLATE.md +1 -0
  45. package/dist/skills/agnostic/planning/create-spec/references/backlog-sync.md +2 -2
  46. package/dist/skills/agnostic/planning/create-spec/references/grill-phase.md +4 -9
  47. package/dist/skills/agnostic/planning/create-spec/references/spec-quality-bar.md +1 -0
  48. package/dist/skills/agnostic/planning/implement-spec/references/lifecycle.md +1 -1
  49. package/dist/skills/agnostic/requirements/grilling/LICENSE +21 -0
  50. package/dist/skills/agnostic/requirements/grilling/SKILL.md +6 -30
  51. package/dist/skills/agnostic/requirements/grilling/UPSTREAM.md +16 -0
  52. package/dist/skills/agnostic/requirements/requirements-grill/SKILL.md +3 -5
  53. package/dist/skills/agnostic/requirements/requirements-grill/references/artifact-output.md +40 -16
  54. package/dist/skills/agnostic/requirements/requirements-grill/references/grilling-flow.md +3 -16
  55. package/dist/skills/agnostic/requirements/write-backlog/REFERENCE.md +21 -15
  56. package/dist/skills/agnostic/requirements/write-backlog/SKILL.md +14 -14
  57. package/dist/skills/agnostic/requirements/write-backlog/assets/concepts/backlog-model.md +28 -9
  58. package/dist/skills/agnostic/requirements/write-backlog/assets/providers/azure-devops-create-payload.md +45 -5
  59. package/dist/skills/agnostic/requirements/write-backlog/assets/providers/github-projects-create-payload.md +48 -28
  60. package/dist/skills/agnostic/requirements/write-backlog/assets/providers/linear-create-payload.md +22 -6
  61. package/dist/skills/agnostic/requirements/write-backlog/assets/providers/monday-create-payload.md +47 -22
  62. package/dist/skills/frameworks/effect/effect/LICENSE +21 -0
  63. package/dist/skills/frameworks/effect/effect/SKILL.md +100 -0
  64. package/dist/skills/frameworks/effect/effect/UPSTREAM.md +11 -0
  65. package/dist/skills/frameworks/effect/effect/references/CACHING.md +76 -0
  66. package/dist/skills/frameworks/effect/effect/references/CONFIG.md +67 -0
  67. package/dist/skills/frameworks/effect/effect/references/HTTP_CLIENTS.md +101 -0
  68. package/dist/skills/frameworks/effect/{effect-authoring/references/otel-patterns.md → effect/references/OBSERVABILITY.md} +4 -29
  69. package/dist/skills/frameworks/effect/effect/references/SCHEDULING.md +135 -0
  70. package/dist/skills/frameworks/effect/effect/references/SCHEMA.md +130 -0
  71. package/dist/skills/frameworks/effect/effect/references/SERVICES_LAYERS.md +168 -0
  72. package/dist/skills/frameworks/effect/effect/references/STREAMS.md +135 -0
  73. package/dist/skills/frameworks/effect/effect/references/TESTING.md +118 -0
  74. package/dist/skills/frameworks/effect/effect-backend-structure/SKILL.md +7 -8
  75. package/dist/skills/frameworks/effect/effect-recoverable-actions/SKILL.md +1 -1
  76. package/dist/skills/frameworks/nestjs/nestjs-best-practices/.gitignore +29 -0
  77. package/dist/skills/misc/secrets-cli/SKILL.md +54 -0
  78. package/dist/skills/misc/secrets-cli/references/command-reference.md +107 -0
  79. package/dist/skills/misc/secrets-cli/references/safety-and-errors.md +54 -0
  80. package/dist/skills/misc/secrets-cli/references/workflows.md +106 -0
  81. package/dist/skills/phases/design-phase/phases/grill.md +1 -1
  82. package/dist/skills/phases/requirements-phase/SKILL.md +2 -4
  83. package/dist/skills/phases/review-phase/REFERENCE.md +13 -5
  84. package/dist/skills/phases/review-phase/SKILL.md +3 -2
  85. package/package.json +1 -1
  86. package/dist/skills/agnostic/planning/create-spec/references/handoff.md +0 -47
  87. package/dist/skills/frameworks/effect/effect-authoring/SKILL.md +0 -116
  88. package/dist/skills/frameworks/effect/effect-authoring/references/branded-types.md +0 -98
  89. package/dist/skills/frameworks/effect/effect-authoring/references/effect-primitives.md +0 -144
  90. package/dist/skills/frameworks/effect/effect-authoring/references/error-patterns.md +0 -156
  91. package/dist/skills/frameworks/effect/effect-authoring/references/test-patterns.md +0 -146
  92. package/dist/skills/frameworks/effect/effect-best-practices/SKILL.md +0 -517
  93. package/dist/skills/frameworks/effect/effect-best-practices/references/anti-patterns.md +0 -392
  94. package/dist/skills/frameworks/effect/effect-best-practices/references/effect-atom-patterns.md +0 -653
  95. package/dist/skills/frameworks/effect/effect-best-practices/references/error-patterns.md +0 -464
  96. package/dist/skills/frameworks/effect/effect-best-practices/references/language-server.md +0 -287
  97. package/dist/skills/frameworks/effect/effect-best-practices/references/layer-patterns.md +0 -495
  98. package/dist/skills/frameworks/effect/effect-best-practices/references/observability-patterns.md +0 -342
  99. package/dist/skills/frameworks/effect/effect-best-practices/references/rpc-cluster-patterns.md +0 -418
  100. package/dist/skills/frameworks/effect/effect-best-practices/references/schema-patterns.md +0 -353
  101. package/dist/skills/frameworks/effect/effect-best-practices/references/service-patterns.md +0 -299
  102. /package/dist/skills/frameworks/effect/{effect-authoring/references/effect-atom-patterns.md → effect/references/EFFECT_ATOM.md} +0 -0
@@ -1,287 +0,0 @@
1
- # Effect Language Server Reference
2
-
3
- The Effect Language Service is a TypeScript language plugin that provides Effect-specific diagnostics, completions, refactors, and hover information. It catches errors that TypeScript alone cannot detect.
4
-
5
- ## Installation
6
-
7
- ```bash
8
- npm install @effect/language-service --save-dev
9
- ```
10
-
11
- Add to `tsconfig.json`:
12
-
13
- ```json
14
- {
15
- "compilerOptions": {
16
- "plugins": [{ "name": "@effect/language-service" }]
17
- }
18
- }
19
- ```
20
-
21
- ## Editor Setup
22
-
23
- ### VSCode
24
-
25
- 1. Install TypeScript workspace version (ensure `typescript` is in devDependencies)
26
- 2. Press F1 → "TypeScript: Select TypeScript Version" → "Use Workspace Version"
27
-
28
- ### JetBrains (WebStorm, IntelliJ)
29
-
30
- Settings → Languages & Frameworks → TypeScript → Select workspace `node_modules/typescript`
31
-
32
- ### Neovim (nvim-lspconfig)
33
-
34
- Configure `tsserver` with the plugin:
35
-
36
- ```lua
37
- require('lspconfig').tsserver.setup({
38
- init_options = {
39
- plugins = {
40
- {
41
- name = "@effect/language-service",
42
- location = vim.fn.getcwd() .. "/node_modules/@effect/language-service"
43
- }
44
- }
45
- }
46
- })
47
- ```
48
-
49
- ### Emacs (lsp-mode)
50
-
51
- ```elisp
52
- (setq lsp-clients-typescript-plugins
53
- (vector (list :name "@effect/language-service"
54
- :location (expand-file-name "node_modules/@effect/language-service"
55
- (projectile-project-root)))))
56
- ```
57
-
58
- ## Configuration Options
59
-
60
- Configure in `tsconfig.json` under the plugin entry:
61
-
62
- ```json
63
- {
64
- "compilerOptions": {
65
- "plugins": [{
66
- "name": "@effect/language-service",
67
- "refactors": { "allEnabled": true },
68
- "diagnostics": { "allEnabled": true },
69
- "quickinfo": { "allEnabled": true },
70
- "completions": { "allEnabled": true }
71
- }]
72
- }
73
- }
74
- ```
75
-
76
- ### Refactors
77
-
78
- | Refactor | Default | Description |
79
- |----------|---------|-------------|
80
- | `asyncAwaitToGenTryPromise` | ✓ | Convert async/await to Effect.gen with Effect.tryPromise |
81
- | `toggleTypeAnnotation` | ✓ | Add/remove return type annotations |
82
- | `wrapWithEffectGen` | ✓ | Wrap selection in Effect.gen |
83
- | `addPipeToEffectUse` | ✓ | Add pipe to effectful expression |
84
- | `arrowToEffectGenFunction` | ✓ | Convert arrow function to Effect.gen |
85
- | `functionToEffectGenFunction` | ✓ | Convert function to Effect.gen |
86
- | `removeLayerCompose` | ✓ | Simplify Layer.compose |
87
-
88
- ### Diagnostics
89
-
90
- | Diagnostic | Default | Description |
91
- |------------|---------|-------------|
92
- | `floatingEffect` | ✓ | Detects unhandled Effect values |
93
- | `missingProvide` | ✓ | Detects missing service requirements |
94
- | `effectYieldNonEffect` | ✓ | Detects yielding non-Effect in generator |
95
- | `noExplicitResourceManagement` | ✓ | Detects missing using/await using |
96
- | `noFloatingPromises` | ✓ | Detects unhandled Promises |
97
- | `forbiddenTags` | ✓ | Detects using forbidden error tags |
98
- | `unnecessaryEffectYield` | ✓ | Detects unnecessary Effect.succeed yield |
99
- | `unnecessaryFlatMap` | ✓ | Detects flatMap that could be map |
100
- | `unnecessaryMap` | ✓ | Detects map with identity function |
101
-
102
- ### Quick Info
103
-
104
- | Feature | Default | Description |
105
- |---------|---------|-------------|
106
- | `showEffectTypeParamsOnHover` | ✓ | Shows Success/Error/Requirements on hover |
107
-
108
- ### Completions
109
-
110
- | Completion | Default | Description |
111
- |------------|---------|-------------|
112
- | `self` | ✓ | Auto-complete `Self` type parameter |
113
- | `durationStrings` | ✓ | Auto-complete Duration.decode strings |
114
- | `brands` | ✓ | Auto-complete Schema brand strings |
115
-
116
- ### Key Patterns
117
-
118
- Configure recognized Effect-like patterns:
119
-
120
- ```json
121
- {
122
- "compilerOptions": {
123
- "plugins": [{
124
- "name": "@effect/language-service",
125
- "keyPatterns": {
126
- "Effect": "Effect\\.Effect",
127
- "Layer": "Layer\\.Layer",
128
- "Stream": "Stream\\.Stream"
129
- }
130
- }]
131
- }
132
- }
133
- ```
134
-
135
- ## CLI Tools
136
-
137
- The language service includes CLI commands for CI/CD integration and development workflows.
138
-
139
- ### Setup Check
140
-
141
- Verify installation:
142
-
143
- ```bash
144
- npx effect-language-service setup
145
- ```
146
-
147
- ### Build-Time Diagnostics
148
-
149
- Patch TypeScript to run language service diagnostics during `tsc`:
150
-
151
- ```bash
152
- npx effect-language-service patch
153
- ```
154
-
155
- This enables CI enforcement of Effect-specific rules. Errors like floating Effects will now fail the build.
156
-
157
- To unpatch:
158
-
159
- ```bash
160
- npx effect-language-service unpatch
161
- ```
162
-
163
- ### Project-Wide Diagnostics
164
-
165
- Run all diagnostics without patching:
166
-
167
- ```bash
168
- npx effect-language-service diagnostics
169
- npx effect-language-service diagnostics --fix # Auto-fix where possible
170
- ```
171
-
172
- ### Quick Fixes
173
-
174
- Apply quick fixes interactively:
175
-
176
- ```bash
177
- npx effect-language-service quickfixes
178
- ```
179
-
180
- ### Code Generation
181
-
182
- Generate boilerplate from Effect patterns:
183
-
184
- ```bash
185
- npx effect-language-service codegen
186
- ```
187
-
188
- ### Project Overview
189
-
190
- Get a summary of Effect usage in your project:
191
-
192
- ```bash
193
- npx effect-language-service overview
194
- ```
195
-
196
- Shows:
197
- - Service definitions
198
- - Error types
199
- - Layer composition graph
200
- - Schema definitions
201
-
202
- ### Layer Information
203
-
204
- Analyze Layer dependencies:
205
-
206
- ```bash
207
- npx effect-language-service layerinfo
208
- npx effect-language-service layerinfo --graph # Output as graph
209
- ```
210
-
211
- ## Common Diagnostics
212
-
213
- ### Floating Effect
214
-
215
- ```typescript
216
- // ERROR: Effect is created but never used
217
- Effect.succeed(42)
218
-
219
- // FIX: Use yield* or pipe to runPromise
220
- yield* Effect.succeed(42)
221
- // or
222
- await Effect.runPromise(Effect.succeed(42))
223
- ```
224
-
225
- ### Missing Requirements
226
-
227
- ```typescript
228
- // ERROR: UserService is required but not provided
229
- const program = UserService.findById(id)
230
- // FIX: Add to Layer composition
231
- const MainLive = Layer.provide(program, UserService.Default)
232
- ```
233
-
234
- ### Yield Non-Effect
235
-
236
- ```typescript
237
- // ERROR: Yielding a non-Effect value
238
- yield* Promise.resolve(42)
239
-
240
- // FIX: Wrap in Effect.promise
241
- yield* Effect.promise(() => Promise.resolve(42))
242
- ```
243
-
244
- ### Forbidden Tags
245
-
246
- ```typescript
247
- // ERROR: "Error" is a forbidden error tag (too generic)
248
- class MyError extends Schema.TaggedError<MyError>()("Error", {}) {}
249
-
250
- // FIX: Use descriptive tag
251
- class UserNotFoundError extends Schema.TaggedError<UserNotFoundError>()(
252
- "UserNotFoundError",
253
- { userId: UserId, message: Schema.String }
254
- ) {}
255
- ```
256
-
257
- ## Troubleshooting
258
-
259
- ### Language Service Not Loading
260
-
261
- 1. Ensure `typescript` is in devDependencies (not just dependencies)
262
- 2. Restart the TypeScript server (VSCode: Cmd+Shift+P → "TypeScript: Restart TS Server")
263
- 3. Verify workspace TypeScript is selected
264
-
265
- ### Diagnostics Not Appearing
266
-
267
- 1. Check `tsconfig.json` plugin configuration
268
- 2. Ensure the file is included in the TypeScript project
269
- 3. Check for `"diagnostics": { "allEnabled": false }` in config
270
-
271
- ### Performance Issues
272
-
273
- For large codebases, disable expensive diagnostics:
274
-
275
- ```json
276
- {
277
- "compilerOptions": {
278
- "plugins": [{
279
- "name": "@effect/language-service",
280
- "diagnostics": {
281
- "allEnabled": true,
282
- "missingProvide": false // Expensive on large projects
283
- }
284
- }]
285
- }
286
- }
287
- ```