Setup Ralph.

This commit is contained in:
2026-01-10 17:13:18 +00:00
parent f15e093254
commit d7ecc2944d
14 changed files with 1287 additions and 11 deletions

20
ralph-sandbox.sh Executable file
View File

@@ -0,0 +1,20 @@
#!/usr/bin/env bash
# ABOUTME: Wrapper script to run Ralph in Nix-isolated environment.
# ABOUTME: Uses the 'ralph' devShell for restricted execution.
# Usage: ./ralph-sandbox.sh [args...]
# Examples:
# ./ralph-sandbox.sh plan 3 # Plan mode, 3 iterations
# ./ralph-sandbox.sh 10 # Build mode, 10 iterations
# ./ralph-sandbox.sh # Build mode, unlimited
set -e
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
echo "━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━"
echo "🔒 Launching Ralph in Nix Sandbox"
echo "━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━"
# Run loop.sh inside the ralph devShell
nix develop "${SCRIPT_DIR}#ralph" --command "${SCRIPT_DIR}/loop.sh" "$@"