Commit 3e2382a
fix(core): accept string commands in workspace hook config (#781)
* fix(core): accept string commands in workspace hook config
Workspace hooks silently ignored string commands (e.g., `command: node scripts/setup.mjs`)
because parseWorkspaceScriptConfig only accepted arrays. Now auto-splits string commands on
whitespace to match user expectations.
Closes #778
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* style: fix lint errors in setup.mjs
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* docs: add JSDoc note about naive whitespace splitting
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* refactor: normalize input early instead of branching to shared helper
Extract parseCommandArray to handle string/array normalization upfront,
keeping parseWorkspaceScriptConfig as a single linear flow.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* test: replace deprecated script field with command in workspace tests
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>1 parent 3a876cc commit 3e2382a
File tree
3 files changed
+57
-17
lines changed- evals/agentic-engineering/workspace-template/scripts
- packages/core
- src/evaluation
- test/evaluation
3 files changed
+57
-17
lines changedLines changed: 3 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
9 | | - | |
10 | 8 | | |
| 9 | + | |
| 10 | + | |
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
| |||
32 | 32 | | |
33 | 33 | | |
34 | 34 | | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
| 35 | + | |
39 | 36 | | |
40 | 37 | | |
41 | 38 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
513 | 513 | | |
514 | 514 | | |
515 | 515 | | |
| 516 | + | |
| 517 | + | |
| 518 | + | |
| 519 | + | |
| 520 | + | |
| 521 | + | |
| 522 | + | |
| 523 | + | |
| 524 | + | |
| 525 | + | |
| 526 | + | |
| 527 | + | |
| 528 | + | |
| 529 | + | |
| 530 | + | |
| 531 | + | |
516 | 532 | | |
517 | 533 | | |
518 | 534 | | |
| 535 | + | |
| 536 | + | |
| 537 | + | |
519 | 538 | | |
520 | 539 | | |
521 | 540 | | |
| |||
527 | 546 | | |
528 | 547 | | |
529 | 548 | | |
530 | | - | |
531 | | - | |
532 | | - | |
533 | | - | |
| 549 | + | |
| 550 | + | |
| 551 | + | |
534 | 552 | | |
535 | 553 | | |
536 | 554 | | |
| |||
540 | 558 | | |
541 | 559 | | |
542 | 560 | | |
543 | | - | |
| 561 | + | |
544 | 562 | | |
545 | 563 | | |
546 | 564 | | |
| |||
Lines changed: 31 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
32 | | - | |
| 32 | + | |
33 | 33 | | |
34 | 34 | | |
35 | | - | |
| 35 | + | |
36 | 36 | | |
37 | 37 | | |
38 | 38 | | |
| |||
81 | 81 | | |
82 | 82 | | |
83 | 83 | | |
84 | | - | |
| 84 | + | |
85 | 85 | | |
86 | 86 | | |
87 | 87 | | |
| |||
112 | 112 | | |
113 | 113 | | |
114 | 114 | | |
115 | | - | |
| 115 | + | |
116 | 116 | | |
117 | 117 | | |
118 | 118 | | |
| |||
121 | 121 | | |
122 | 122 | | |
123 | 123 | | |
124 | | - | |
| 124 | + | |
125 | 125 | | |
126 | 126 | | |
127 | 127 | | |
| |||
158 | 158 | | |
159 | 159 | | |
160 | 160 | | |
161 | | - | |
| 161 | + | |
162 | 162 | | |
163 | 163 | | |
164 | 164 | | |
| |||
337 | 337 | | |
338 | 338 | | |
339 | 339 | | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
| 344 | + | |
| 345 | + | |
| 346 | + | |
| 347 | + | |
| 348 | + | |
| 349 | + | |
| 350 | + | |
| 351 | + | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
340 | 365 | | |
341 | 366 | | |
342 | 367 | | |
| |||
0 commit comments