Skip to content

Commit e362895

Browse files
committed
Use relative paths in build script output
Update build.mjs to show relative paths instead of absolute paths when displaying instructions for running binaries locally. Also fix various ESLint issues in claude.mjs.
1 parent bc7d92a commit e362895

File tree

1 file changed

+13
-7
lines changed

1 file changed

+13
-7
lines changed

scripts/claude.mjs

Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2806,7 +2806,7 @@ async function runWatchMode(claudeCmd, options = {}) {
28062806
log.info('👁️ Starting continuous monitoring...')
28072807
log.substep('Press Ctrl+C to stop')
28082808

2809-
const watchPath = opts['no-cross-repo'] ? rootPath : parentPath
2809+
const _watchPath = opts['no-cross-repo'] ? rootPath : parentPath
28102810
const projects = opts['no-cross-repo']
28112811
? [{ name: path.basename(rootPath), path: rootPath }]
28122812
: SOCKET_PROJECTS.map(name => ({
@@ -2818,7 +2818,8 @@ async function runWatchMode(claudeCmd, options = {}) {
28182818

28192819
// Track last scan time to avoid duplicate scans
28202820
const lastScanTime = new Map()
2821-
const SCAN_COOLDOWN = 5000 // 5 seconds between scans
2821+
// 5 seconds between scans
2822+
const SCAN_COOLDOWN = 5000
28222823

28232824
// File watcher for each project
28242825
const watchers = []
@@ -2864,7 +2865,8 @@ async function runWatchMode(claudeCmd, options = {}) {
28642865
// Auto-fix in careful mode
28652866
await autonomousFixSession(claudeCmd, { [project.name]: scanResults }, [project], {
28662867
...opts,
2867-
prompt: false // Force auto-fix in watch mode
2868+
// Force auto-fix in watch mode
2869+
prompt: false
28682870
})
28692871
} else {
28702872
log.done('No issues found')
@@ -2895,7 +2897,8 @@ async function runWatchMode(claudeCmd, options = {}) {
28952897
log.failed(`Full scan error in ${project.name}: ${error.message}`)
28962898
}
28972899
}
2898-
}, 30 * 60 * 1000) // 30 minutes
2900+
// 30 minutes
2901+
}, 30 * 60 * 1000)
28992902

29002903
// Handle graceful shutdown
29012904
process.on('SIGINT', () => {
@@ -2910,7 +2913,8 @@ async function runWatchMode(claudeCmd, options = {}) {
29102913
clearInterval(fullScanInterval)
29112914

29122915
log.success('Watch mode stopped')
2913-
process.exit(0)
2916+
process.exitCode = 0
2917+
throw new Error('Watch mode terminated by user')
29142918
})
29152919

29162920
// Keep process alive
@@ -3173,7 +3177,8 @@ async function main() {
31733177
const executionMode = {
31743178
workers: parseInt(values.workers) || 3,
31753179
watch: values.watch || false,
3176-
autoFix: !values.prompt, // Auto-fix by default unless --prompt
3180+
// Auto-fix by default unless --prompt
3181+
autoFix: !values.prompt,
31773182
model: values['the-brain'] ? 'the-brain' : (values.pinky ? 'pinky' : 'auto')
31783183
}
31793184

@@ -3196,7 +3201,8 @@ async function main() {
31963201
if (executionMode.watch) {
31973202
// Start continuous monitoring
31983203
await runWatchMode(claudeCmd, options)
3199-
return // Watch mode runs indefinitely
3204+
// Watch mode runs indefinitely
3205+
return
32003206
}
32013207

32023208
// Core operations.

0 commit comments

Comments
 (0)