codex-ralph 0.3.2 → 0.4.0

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/README.md CHANGED
@@ -5,7 +5,7 @@ Minimal Ralph Wiggum Loop runner that feeds a sprint requirement into Codex, one
5
5
  ## Quick start
6
6
 
7
7
  ```bash
8
- npx codex-ralph --sprint=path/to/Sprint_0001.md --max-iterations=1
8
+ npx codex-ralph path/to/Sprint_0001.md --max-iterations=1
9
9
  ```
10
10
 
11
11
  ## Telegram progress notifications
@@ -19,6 +19,18 @@ CODEX_RALPH_TG_CHAT=123456789
19
19
 
20
20
  Provide these as environment variables (e.g., when invoking `npx`). Each session generates a UUID and includes it in progress messages.
21
21
 
22
+ Usage:
23
+
24
+ ```
25
+ npx codex-ralph path/to/Sprint_0001.md
26
+ ```
27
+
28
+ Optional flags:
29
+
30
+ ```
31
+ --max-iterations=10
32
+ ```
33
+
22
34
  Message format:
23
35
 
24
36
  ```
@@ -9,7 +9,7 @@ PY
9
9
  )"
10
10
  ROOT_DIR="$(cd "$(dirname "$SCRIPT_PATH")/.." && pwd)"
11
11
  SPRINT_FILE=""
12
- MAX_ITERATIONS=0
12
+ MAX_ITERATIONS=10
13
13
  NOTES_FILE=""
14
14
  SESSION_UUID=""
15
15
 
@@ -40,11 +40,11 @@ send_telegram() {
40
40
 
41
41
  usage() {
42
42
  cat <<USAGE
43
- Usage: ralph-loop --sprint=PATH [--max-iterations=N]
43
+ Usage: ralph-loop SPRINT_PATH [--max-iterations=N]
44
44
 
45
45
  Options:
46
- --sprint=PATH Path to the sprint markdown file (required).
47
- --max-iterations=N Stop after N iterations (0 = no limit).
46
+ SPRINT_PATH Path to the sprint markdown file (required).
47
+ --max-iterations=N Stop after N iterations (0 = no limit, default 10).
48
48
  -h, --help Show this help.
49
49
  USAGE
50
50
  }
@@ -53,9 +53,6 @@ session_uuid >/dev/null
53
53
 
54
54
  for arg in "$@"; do
55
55
  case "$arg" in
56
- --sprint=*)
57
- SPRINT_FILE="${arg#*=}"
58
- ;;
59
56
  --max-iterations=*)
60
57
  MAX_ITERATIONS="${arg#*=}"
61
58
  ;;
@@ -63,11 +60,20 @@ for arg in "$@"; do
63
60
  usage
64
61
  exit 0
65
62
  ;;
66
- *)
63
+ -*)
67
64
  echo "Unknown argument: $arg" >&2
68
65
  usage >&2
69
66
  exit 1
70
67
  ;;
68
+ *)
69
+ if [[ -z "$SPRINT_FILE" ]]; then
70
+ SPRINT_FILE="$arg"
71
+ else
72
+ echo "Unexpected argument: $arg" >&2
73
+ usage >&2
74
+ exit 1
75
+ fi
76
+ ;;
71
77
  esac
72
78
  done
73
79
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "codex-ralph",
3
- "version": "0.3.2",
3
+ "version": "0.4.0",
4
4
  "description": "Ralph Loop sprint runner for Codex.",
5
5
  "bin": {
6
6
  "ralph-loop": "agent/ralph-loop.sh"