@walwal-harness/cli 3.6.0 → 3.6.1
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.
- package/bin/init.js +37 -6
- package/package.json +1 -1
package/bin/init.js
CHANGED
|
@@ -14,9 +14,11 @@ const path = require('path');
|
|
|
14
14
|
const { execSync } = require('child_process');
|
|
15
15
|
|
|
16
16
|
const PKG_ROOT = path.resolve(__dirname, '..');
|
|
17
|
-
const
|
|
18
|
-
const
|
|
19
|
-
const
|
|
17
|
+
const args = process.argv.slice(2);
|
|
18
|
+
const subcommand = args.find(a => !a.startsWith('-')) || null;
|
|
19
|
+
const isAuto = args.includes('--auto');
|
|
20
|
+
const isForce = args.includes('--force');
|
|
21
|
+
const isHelp = args.includes('--help') || args.includes('-h');
|
|
20
22
|
|
|
21
23
|
// ─────────────────────────────────────────
|
|
22
24
|
// Resolve project root
|
|
@@ -551,9 +553,11 @@ function showHelp() {
|
|
|
551
553
|
╚══════════════════════════════════════╝
|
|
552
554
|
|
|
553
555
|
Usage:
|
|
554
|
-
npx walwal-harness
|
|
555
|
-
npx walwal-harness --force
|
|
556
|
-
npx walwal-harness
|
|
556
|
+
npx walwal-harness Initialize project for harness engineering
|
|
557
|
+
npx walwal-harness --force Re-initialize (overwrites existing files)
|
|
558
|
+
npx walwal-harness studio Launch Harness Studio (tmux 4-pane monitor)
|
|
559
|
+
npx walwal-harness studio --ai Studio + AI eval summary (API cost)
|
|
560
|
+
npx walwal-harness --help Show this help
|
|
557
561
|
|
|
558
562
|
What it does:
|
|
559
563
|
1. Scaffolds .harness/ directory (actions, archive, gotchas, config)
|
|
@@ -580,12 +584,39 @@ After init:
|
|
|
580
584
|
// ─────────────────────────────────────────
|
|
581
585
|
// Main
|
|
582
586
|
// ─────────────────────────────────────────
|
|
587
|
+
function runStudio() {
|
|
588
|
+
const useAi = args.includes('--ai') ? '--ai' : '';
|
|
589
|
+
const scriptsDir = path.join(PKG_ROOT, 'scripts');
|
|
590
|
+
const tmuxScript = path.join(scriptsDir, 'harness-tmux.sh');
|
|
591
|
+
|
|
592
|
+
if (!fs.existsSync(tmuxScript)) {
|
|
593
|
+
log('ERROR: harness-tmux.sh not found. Update @walwal-harness/cli to >= 3.6.0');
|
|
594
|
+
process.exit(1);
|
|
595
|
+
}
|
|
596
|
+
|
|
597
|
+
try {
|
|
598
|
+
execSync('which tmux', { stdio: 'ignore' });
|
|
599
|
+
} catch {
|
|
600
|
+
log('ERROR: tmux is required. Install with: brew install tmux');
|
|
601
|
+
process.exit(1);
|
|
602
|
+
}
|
|
603
|
+
|
|
604
|
+
const cmd = `bash "${tmuxScript}" "${PROJECT_ROOT}" ${useAi}`.trim();
|
|
605
|
+
log(`Launching Harness Studio...`);
|
|
606
|
+
execSync(cmd, { stdio: 'inherit' });
|
|
607
|
+
}
|
|
608
|
+
|
|
583
609
|
function main() {
|
|
584
610
|
if (isHelp) {
|
|
585
611
|
showHelp();
|
|
586
612
|
return;
|
|
587
613
|
}
|
|
588
614
|
|
|
615
|
+
if (subcommand === 'studio') {
|
|
616
|
+
runStudio();
|
|
617
|
+
return;
|
|
618
|
+
}
|
|
619
|
+
|
|
589
620
|
const pkg = require(path.join(PKG_ROOT, 'package.json'));
|
|
590
621
|
console.log('');
|
|
591
622
|
console.log('╔══════════════════════════════════════╗');
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@walwal-harness/cli",
|
|
3
|
-
"version": "3.6.
|
|
3
|
+
"version": "3.6.1",
|
|
4
4
|
"description": "Production harness for AI agent engineering — Planner, Generator(BE/FE), Evaluator(Func/Visual), optional Brainstormer (requirements refinement). Supports React and Flutter FE stacks.",
|
|
5
5
|
"bin": {
|
|
6
6
|
"walwal-harness": "bin/init.js"
|