This commit is contained in:
Harivansh Rathi 2026-01-22 14:46:48 -05:00
commit f1df2259ca
3 changed files with 515 additions and 0 deletions

39
install.sh Executable file
View file

@ -0,0 +1,39 @@
#!/bin/bash
set -e
# Ralph CLI Installer
INSTALL_DIR="$HOME/.local/bin"
REPO_URL="https://raw.githubusercontent.com/rathi/ralph-cli/main/ralph"
echo "Installing Ralph CLI..."
# Create install directory if needed
mkdir -p "$INSTALL_DIR"
# Download or copy ralph
if [ -f "$(dirname "$0")/ralph" ]; then
# Local install
cp "$(dirname "$0")/ralph" "$INSTALL_DIR/ralph"
else
# Remote install
curl -fsSL "$REPO_URL" -o "$INSTALL_DIR/ralph"
fi
chmod +x "$INSTALL_DIR/ralph"
# Check if in PATH
if [[ ":$PATH:" != *":$INSTALL_DIR:"* ]]; then
echo ""
echo "Add this to your shell profile (.bashrc, .zshrc, etc.):"
echo ""
echo " export PATH=\"\$HOME/.local/bin:\$PATH\""
echo ""
fi
echo "Ralph installed to $INSTALL_DIR/ralph"
echo ""
echo "Usage:"
echo " ralph init # Initialize in a repo"
echo " ralph run 10 # Run 10 iterations"
echo " ralph --help # See all options"