// Test: call agentAcceptAllInFile via extension's HTTP bridge trigger-click // This simulates what the approval handler does const http = require('http'); const PORT = 34332; // from observer setup log // Write a trigger-click file to make Observer click "Accept all" const fs = require('fs'); const path = require('path'); const bridgePath = path.join(process.env.USERPROFILE, '.gemini', 'antigravity', 'bridge'); // Check if there's a trigger_click.json const triggerFile = path.join(bridgePath, 'trigger_click.json'); console.log('Writing trigger_click.json for accept...'); fs.writeFileSync(triggerFile, JSON.stringify({ action: 'approve', type: 'diff_review', ts: Date.now() }), 'utf-8'); console.log('Done. Check if Accept all was clicked.'); // Also check extension log for recent entries const logFile = path.join(bridgePath, 'extension.log'); const lines = fs.readFileSync(logFile, 'utf-8').split('\n'); const recent = lines.slice(-5); recent.forEach(l => console.log(l.substring(0, 200)));