mirror of
https://github.com/harivansh-afk/ralph-cli.git
synced 2026-04-15 07:04:48 +00:00
init
This commit is contained in:
commit
f1df2259ca
3 changed files with 515 additions and 0 deletions
39
install.sh
Executable file
39
install.sh
Executable 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"
|
||||
Loading…
Add table
Add a link
Reference in a new issue