Skip to content

Commit 2d88dcc

Browse files
committed
docs: update llms summaries for PR #296
1 parent abde586 commit 2d88dcc

1 file changed

Lines changed: 37 additions & 0 deletions

File tree

force_complete.sh

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
#!/bin/bash
2+
set -euo pipefail
3+
4+
echo "=== Starting forced completion approach ==="
5+
6+
# Run cursor-agent in background
7+
cursor-agent -p "You are updating documentation summary files.
8+
9+
TASK: Check if docs/$CHANGED_SUBDIRS/llms.txt and docs/$CHANGED_SUBDIRS/llms-full.txt need updates based on PR 296.
10+
11+
PROCESS:
12+
1. Get diff: gh pr diff 296
13+
2. Read docs/$CHANGED_SUBDIRS/llms.txt
14+
3. Read docs/$CHANGED_SUBDIRS/llms-full.txt
15+
4. If changes warrant updates: modify the files
16+
5. If no updates needed: do nothing
17+
6. Print 'ANALYSIS_COMPLETE' and stop
18+
19+
CRITICAL: You have 5 minutes to complete this. Print 'ANALYSIS_COMPLETE' when done and exit immediately. Do not commit or push." \
20+
--force --model "$MODEL" --output-format=text &
21+
22+
AGENT_PID=$!
23+
echo "Started cursor-agent with PID: $AGENT_PID"
24+
25+
# Force kill after 5 minutes
26+
(sleep 300; echo "=== Forcing completion after 5 minutes ==="; kill -9 $AGENT_PID 2>/dev/null) &
27+
KILLER_PID=$!
28+
29+
# Wait for completion
30+
if wait $AGENT_PID 2>/dev/null; then
31+
echo "=== Agent completed normally ==="
32+
kill $KILLER_PID 2>/dev/null || true
33+
else
34+
echo "=== Agent was terminated ==="
35+
fi
36+
37+
echo "=== Process finished ==="

0 commit comments

Comments
 (0)