diff --git a/scripts/bootstrap-agents.sh b/scripts/bootstrap-agents.sh index c87a66d..be75102 100755 --- a/scripts/bootstrap-agents.sh +++ b/scripts/bootstrap-agents.sh @@ -8,12 +8,14 @@ # - Clones or updates the homelab-agents repo # - Sets up git remotes for pushing VPS work # - Makes agents available for Claude Code +# - Installs helper scripts (init-project) set -e GITEA_URL="http://100.120.125.113:3000" AGENTS_REPO="$GITEA_URL/pdm/homelab-agents.git" AGENTS_DIR="$HOME/.homelab-agents" +SCRIPTS_DIR="$HOME/.homelab-scripts" echo "🔧 Bootstrapping homelab agents..." @@ -43,15 +45,35 @@ else fi fi +# Install helper scripts +echo "" +echo "📋 Installing helper scripts..." +mkdir -p "$SCRIPTS_DIR" + +if [[ -f "$AGENTS_DIR/scripts/init-project.sh" ]]; then + cp "$AGENTS_DIR/scripts/init-project.sh" "$SCRIPTS_DIR/init-project" + chmod +x "$SCRIPTS_DIR/init-project" + echo "✅ init-project installed" +fi + +# Add scripts directory to PATH if not already there +if [[ ":$PATH:" != *":$SCRIPTS_DIR:"* ]]; then + export PATH="$SCRIPTS_DIR:$PATH" + echo "✅ Scripts directory added to PATH" +fi + # Verify agents are available if [[ -f "$AGENTS_DIR/agents/sysadmin-session-closer.md" ]]; then echo "✅ sysadmin-session-closer agent available" - echo "" - echo "📋 Agent location: $AGENTS_DIR/agents/sysadmin-session-closer.md" - echo "🚀 Use in Claude Code: Include the agent from this path" else echo "⚠️ Warning: sysadmin-session-closer.md not found" fi echo "" -echo "✨ Homelab agents bootstrap complete!" \ No newline at end of file +echo "✨ Homelab agents bootstrap complete!" +echo "" +echo "📚 Available commands:" +echo " init-project - Initialize a new project with git remote" +echo " cd ~/.homelab-agents - Browse agents and scripts" +echo "" +echo "📋 Agent location: $AGENTS_DIR/agents/sysadmin-session-closer.md" \ No newline at end of file