claude-fsd 1.6.0 → 1.6.2

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.
@@ -15,11 +15,16 @@ command_exists() {
15
15
  check_dependencies() {
16
16
  local missing_deps=()
17
17
 
18
- # Check for claude (only required dependency)
18
+ # Check for claude (required)
19
19
  if ! command_exists claude; then
20
20
  missing_deps+=("claude")
21
21
  fi
22
22
 
23
+ # Check for jq (required for JSON output parsing)
24
+ if ! command_exists jq; then
25
+ missing_deps+=("jq")
26
+ fi
27
+
23
28
  # Show critical errors
24
29
  if [ ${#missing_deps[@]} -ne 0 ]; then
25
30
  echo -e "${RED}❌ Missing required dependencies:${NC}"
@@ -27,6 +32,8 @@ check_dependencies() {
27
32
  echo -e " - $dep"
28
33
  if [ "$dep" = "claude" ]; then
29
34
  echo -e " Install from: https://docs.anthropic.com/en/docs/claude-code"
35
+ elif [ "$dep" = "jq" ]; then
36
+ echo -e " Install: brew install jq (macOS) or apt install jq (Linux)"
30
37
  fi
31
38
  done
32
39
  echo
package/bin/claudefsd-dev CHANGED
@@ -263,16 +263,17 @@ When using parallel Task agents, ensure each one:
263
263
 
264
264
  IMPORTANT: You must ACTUALLY IMPLEMENT tasks, not just describe what should be done. Use Edit, Write, Bash, and Task tools to complete real work. Begin by analyzing $plan_file and then IMPLEMENT the next task in order."
265
265
 
266
- # Save the prompt to the log file first
267
- echo "=== DEVELOPMENT PROMPT ===" > $LOGFILE
268
- echo "$DEVELOPMENT_PROMPT" >> $LOGFILE
269
- echo "=== END PROMPT ===" >> $LOGFILE
266
+ # Save the prompt to the log file and print to screen
267
+ echo "=== DEVELOPMENT PROMPT ===" | tee $LOGFILE
268
+ echo "$DEVELOPMENT_PROMPT" | tee -a $LOGFILE
269
+ echo "=== END PROMPT ===" | tee -a $LOGFILE
270
270
  echo "" >> $LOGFILE
271
271
  echo "=== OUTPUT ===" >> $LOGFILE
272
272
 
273
273
  # Run claude and append output to the log file
274
- echo "Running development with $CLAUDE_MODEL model..."
275
- time claude --model $CLAUDE_MODEL --dangerously-skip-permissions -p "$DEVELOPMENT_PROMPT" 2>&1 | tee -a $LOGFILE
274
+ # Raw JSON goes to log, filtered text to screen
275
+ echo -e "\033[36mRunning development with $CLAUDE_MODEL model...\033[0m"
276
+ time claude --model $CLAUDE_MODEL --print --verbose --output-format=stream-json --include-partial-messages --dangerously-skip-permissions -p "$DEVELOPMENT_PROMPT" 2>&1 | tee -a $LOGFILE | jq --unbuffered -r 'if .type == "assistant" then (.message.content[]? | if .type == "text" then .text elif .type == "tool_use" then "\n[TOOL: " + .name + "]\n" else empty end) // empty elif .type == "stream_event" and .event == "content_block_start" and .content_block.type == "tool_use" then "\n[TOOL: " + .content_block.name + "]\n" elif .type == "result" then "\n=== RESULT ===\n" + (.result // "no result") else empty end'
276
277
 
277
278
  # Extract what task was worked on from the developer's output
278
279
  DEVELOPER_OUTPUT=$(sed -n '/=== OUTPUT ===/,$p' $LOGFILE)
@@ -317,14 +318,16 @@ $DEVELOPER_OUTPUT
317
318
  Be thorough but concise in your code review."
318
319
 
319
320
  VERIFIER_LOGFILE="${LOGFILE}-verifier"
320
- echo "=== VERIFIER PROMPT ===" > $VERIFIER_LOGFILE
321
- echo "$VERIFIER_PROMPT" >> $VERIFIER_LOGFILE
322
- echo "=== END PROMPT ===" >> $VERIFIER_LOGFILE
321
+ echo "=== VERIFIER PROMPT ===" | tee $VERIFIER_LOGFILE
322
+ echo "$VERIFIER_PROMPT" | tee -a $VERIFIER_LOGFILE
323
+ echo "=== END PROMPT ===" | tee -a $VERIFIER_LOGFILE
323
324
  echo "" >> $VERIFIER_LOGFILE
324
325
  echo "=== OUTPUT ===" >> $VERIFIER_LOGFILE
325
326
 
326
327
  # Run verifier
327
- time claude --model $CLAUDE_MODEL --dangerously-skip-permissions -p "$VERIFIER_PROMPT" 2>&1 | tee -a $VERIFIER_LOGFILE
328
+ # Raw JSON goes to log, filtered text to screen
329
+ echo -e "\033[36mRunning verifier with $CLAUDE_MODEL model...\033[0m"
330
+ time claude --model $CLAUDE_MODEL --print --verbose --output-format=stream-json --include-partial-messages --dangerously-skip-permissions -p "$VERIFIER_PROMPT" 2>&1 | tee -a $VERIFIER_LOGFILE | jq --unbuffered -r 'if .type == "assistant" then (.message.content[]? | if .type == "text" then .text elif .type == "tool_use" then "\n[TOOL: " + .name + "]\n" else empty end) // empty elif .type == "stream_event" and .event == "content_block_start" and .content_block.type == "tool_use" then "\n[TOOL: " + .content_block.name + "]\n" elif .type == "result" then "\n=== RESULT ===\n" + (.result // "no result") else empty end'
328
331
 
329
332
  # Extract verifier output for the tester
330
333
  VERIFIER_OUTPUT=$(sed -n '/=== OUTPUT ===/,$p' $VERIFIER_LOGFILE)
@@ -391,15 +394,16 @@ If ALL tasks in the plan are complete AND all tests pass, output: <VERIFIED_ALL_
391
394
  "
392
395
 
393
396
  TESTER_LOGFILE="${LOGFILE}-tester"
394
- echo "=== TESTER PROMPT ===" > $TESTER_LOGFILE
395
- echo "$TESTER_PROMPT" >> $TESTER_LOGFILE
396
- echo "=== END PROMPT ===" >> $TESTER_LOGFILE
397
+ echo "=== TESTER PROMPT ===" | tee $TESTER_LOGFILE
398
+ echo "$TESTER_PROMPT" | tee -a $TESTER_LOGFILE
399
+ echo "=== END PROMPT ===" | tee -a $TESTER_LOGFILE
397
400
  echo "" >> $TESTER_LOGFILE
398
401
  echo "=== OUTPUT ===" >> $TESTER_LOGFILE
399
402
 
400
403
  # Run tester
401
- echo "Running tester with $CLAUDE_MODEL model..."
402
- time claude --model $CLAUDE_MODEL --dangerously-skip-permissions -p "$TESTER_PROMPT" 2>&1 | tee -a $TESTER_LOGFILE
404
+ # Raw JSON goes to log, filtered text to screen
405
+ echo -e "\033[36mRunning tester with $CLAUDE_MODEL model...\033[0m"
406
+ time claude --model $CLAUDE_MODEL --print --verbose --output-format=stream-json --include-partial-messages --dangerously-skip-permissions -p "$TESTER_PROMPT" 2>&1 | tee -a $TESTER_LOGFILE | jq --unbuffered -r 'if .type == "assistant" then (.message.content[]? | if .type == "text" then .text elif .type == "tool_use" then "\n[TOOL: " + .name + "]\n" else empty end) // empty elif .type == "stream_event" and .event == "content_block_start" and .content_block.type == "tool_use" then "\n[TOOL: " + .content_block.name + "]\n" elif .type == "result" then "\n=== RESULT ===\n" + (.result // "no result") else empty end'
403
407
 
404
408
  # Check if tests failed
405
409
  if sed -n '/=== OUTPUT ===/,$p' $TESTER_LOGFILE | grep -q "<TESTS_FAILED>"; then
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "claude-fsd",
3
- "version": "1.6.0",
3
+ "version": "1.6.2",
4
4
  "description": "Claude Full Self Drive tools for autonomous AI-powered development",
5
5
  "bin": {
6
6
  "claude-fsd": "bin/claude-fsd",