Skip to content

Commit 8a886f2

Browse files
authored
Merge pull request #9 from ryanmac/feature/installer-environment-selection
Add development environment selection to installer
2 parents a912ad1 + 182a929 commit 8a886f2

File tree

1 file changed

+136
-51
lines changed

1 file changed

+136
-51
lines changed

conductor-init.sh

Lines changed: 136 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -366,66 +366,151 @@ else:
366366
" || echo -e "${YELLOW}⚠️ Could not create demo tasks.${NC}"
367367
fi
368368

369-
# Step 8: Launch Agent (improved: handle uncommitted changes)
369+
# Step 8: Development Environment Selection
370370
echo ""
371-
read -p "Would you like to start a dev agent now? [Y/n]: " -n 1 -r
371+
echo -e "${YELLOW}🖥️ Select your primary development environment:${NC}"
372372
echo ""
373-
if [[ $REPLY =~ ^[Yy]$ ]] || [[ -z $REPLY ]]; then
374-
echo -e "${YELLOW}🤖 Starting dev agent...${NC}"
375-
376-
# Check for uncommitted changes
377-
if ! git diff-index --quiet HEAD -- 2>/dev/null; then
378-
echo -e "${YELLOW}⚠️ Uncommitted changes detected.${NC}"
379-
read -p "Stash them automatically before starting agent? [Y/n]: " -n 1 -r
373+
echo " 1) Conductor (https://conductor.build - macOS only)"
374+
echo " 2) Terminal (Warp, iTerm2, Windows Terminal, etc.)"
375+
echo " 3) IDE (Cursor, Cline, Windsurf, VSCode, etc.)"
376+
echo ""
377+
read -p "Enter your choice [1-3]: " -n 1 -r ENV_CHOICE
378+
echo ""
379+
380+
case "$ENV_CHOICE" in
381+
1)
382+
# Conductor App Flow
383+
if [[ "$OSTYPE" != "darwin"* ]]; then
384+
echo -e "${YELLOW}⚠️ Conductor app is currently macOS-only.${NC}"
385+
echo "Please select Terminal or IDE option instead."
386+
exit 0
387+
fi
388+
389+
echo -e "${GREEN}🎼 Conductor App Setup${NC}"
390+
echo "=========================================="
391+
echo ""
392+
echo "📋 Next Steps:"
393+
echo ""
394+
echo "1. Open Conductor app:"
395+
echo " ${GREEN}open -a Conductor${NC}"
396+
echo ""
397+
echo "2. Add this project as a workspace:"
398+
echo " • In Conductor: ${YELLOW}File → Add Workspace${NC}"
399+
echo " • Select directory: ${GREEN}$(pwd)${NC}"
400+
echo ""
401+
echo "3. Start working with this prompt:"
402+
echo ""
403+
echo " ${YELLOW}\"Check available tasks and start working on the highest priority one.\"${NC}"
404+
echo ""
405+
echo "💡 Pro Tips:"
406+
echo " • Conductor will handle task claiming and worktree setup automatically"
407+
echo " • Use the built-in terminal for git operations"
408+
echo " • AI code reviews happen automatically on PRs"
409+
echo ""
410+
echo "📚 Learn more: https://conductor.build"
411+
;;
412+
413+
2|3)
414+
# Terminal/IDE Flow - Run bootstrap
415+
if [ "$ENV_CHOICE" = "2" ]; then
416+
echo -e "${GREEN}🖥️ Terminal Workflow${NC}"
417+
else
418+
echo -e "${GREEN}💻 IDE Workflow${NC}"
419+
fi
420+
echo "=========================================="
421+
echo ""
422+
423+
read -p "Would you like to start a dev agent now? [Y/n]: " -n 1 -r
380424
echo ""
381425
if [[ $REPLY =~ ^[Yy]$ ]] || [[ -z $REPLY ]]; then
382-
git stash push -m "Auto-stash before Conductor agent startup" || {
383-
echo -e "${RED}❌ Failed to stash changes.${NC}"
384-
echo "Please commit or stash changes manually, then run: bash .conductor/scripts/bootstrap.sh dev"
385-
exit 1
426+
echo -e "${YELLOW}🤖 Starting dev agent...${NC}"
427+
428+
# Check for uncommitted changes
429+
if ! git diff-index --quiet HEAD -- 2>/dev/null; then
430+
echo -e "${YELLOW}⚠️ Uncommitted changes detected.${NC}"
431+
read -p "Stash them automatically before starting agent? [Y/n]: " -n 1 -r
432+
echo ""
433+
if [[ $REPLY =~ ^[Yy]$ ]] || [[ -z $REPLY ]]; then
434+
git stash push -m "Auto-stash before Conductor agent startup" || {
435+
echo -e "${RED}❌ Failed to stash changes.${NC}"
436+
echo "Please commit or stash changes manually, then run: bash .conductor/scripts/bootstrap.sh dev"
437+
exit 1
438+
}
439+
echo -e "${GREEN}✅ Changes stashed. You can restore them later with: git stash pop${NC}"
440+
else
441+
echo -e "${YELLOW}⚠️ Skipping agent startup. Please handle uncommitted changes first.${NC}"
442+
echo "Then run: bash .conductor/scripts/bootstrap.sh dev"
443+
exit 0
444+
fi
445+
fi
446+
447+
bash .conductor/scripts/bootstrap.sh dev || {
448+
echo -e "${YELLOW}⚠️ Agent startup failed.${NC}"
449+
echo "You can try again with: bash .conductor/scripts/bootstrap.sh dev"
450+
if git stash list | grep -q "Auto-stash before Conductor"; then
451+
echo "To restore your stashed changes: git stash pop"
452+
fi
386453
}
387-
echo -e "${GREEN}✅ Changes stashed. You can restore them later with: git stash pop${NC}"
388454
else
389-
echo -e "${YELLOW}⚠️ Skipping agent startup. Please handle uncommitted changes first.${NC}"
390-
echo "Then run: bash .conductor/scripts/bootstrap.sh dev"
391-
exit 0
455+
echo ""
456+
echo "📋 To start an agent later:"
457+
echo " ${GREEN}bash .conductor/scripts/bootstrap.sh dev${NC}"
392458
fi
393-
fi
394-
395-
bash .conductor/scripts/bootstrap.sh dev || {
396-
echo -e "${YELLOW}⚠️ Agent startup failed.${NC}"
397-
echo "You can try again with: bash .conductor/scripts/bootstrap.sh dev"
398-
if git stash list | grep -q "Auto-stash before Conductor"; then
399-
echo "To restore your stashed changes: git stash pop"
400-
fi
401-
}
402-
fi
459+
;;
460+
461+
*)
462+
echo -e "${RED}❌ Invalid choice. Please run the installer again.${NC}"
463+
exit 1
464+
;;
465+
esac
403466

404467
# Note: No cleanup of setup.py, requirements.txt, etc. - leaving them in place for user reference and future use.
405468

406-
# Step 9: Next Steps (enhanced with copy-pasteable commands)
407-
echo ""
408-
echo -e "${GREEN}🎉 Installation Successful!${NC}"
409-
echo "=========================================="
410-
echo "Code Conductor is now installed with:"
411-
if [ -n "$DETECTED_STACKS" ]; then
412-
echo " ✅ Auto-detected: $DETECTED_STACKS"
469+
# Step 9: Next Steps (contextual based on environment choice)
470+
if [ "$ENV_CHOICE" != "1" ]; then
471+
# Terminal/IDE users get the full command list
472+
echo ""
473+
echo -e "${GREEN}🎉 Installation Successful!${NC}"
474+
echo "=========================================="
475+
echo "Code Conductor is now installed with:"
476+
if [ -n "$DETECTED_STACKS" ]; then
477+
echo " ✅ Auto-detected: $DETECTED_STACKS"
478+
else
479+
echo " ✅ Auto-detected technology stack"
480+
fi
481+
echo " ✅ AI code-reviewer for all PRs"
482+
echo " ✅ Specialized roles: ${CONFIGURED_ROLES}"
483+
echo " ✅ Demo tasks ready to claim"
484+
echo ""
485+
echo "${YELLOW}Quick Start Commands:${NC}"
486+
echo " 📋 View tasks: ${GREEN}cat .conductor/workflow-state.json | jq '.available_tasks'${NC}"
487+
echo " 🤖 Start agent: ${GREEN}bash .conductor/scripts/bootstrap.sh dev${NC}"
488+
echo " 📝 Create task: ${GREEN}gh issue create -l 'conductor:task'${NC}"
489+
echo " 🔧 Adjust config: ${GREEN}$EDITOR .conductor/config.yaml${NC}"
490+
echo ""
491+
echo "${YELLOW}Your first PR will automatically get AI code reviews!${NC}"
492+
echo ""
493+
echo "📚 Documentation: https://github.com/ryanmac/code-conductor"
494+
echo "🐛 Report issues: https://github.com/ryanmac/code-conductor/issues"
495+
echo ""
496+
echo -e "${GREEN}Happy orchestrating! 🎼${NC}"
413497
else
414-
echo " ✅ Auto-detected technology stack"
498+
# Conductor app users get a simplified message (already shown above)
499+
echo ""
500+
echo -e "${GREEN}🎉 Setup Complete!${NC}"
501+
echo "=========================================="
502+
echo "Code Conductor is configured with:"
503+
if [ -n "$DETECTED_STACKS" ]; then
504+
echo " ✅ Auto-detected: $DETECTED_STACKS"
505+
else
506+
echo " ✅ Auto-detected technology stack"
507+
fi
508+
echo " ✅ AI code-reviewer for all PRs"
509+
echo " ✅ Specialized roles: ${CONFIGURED_ROLES}"
510+
echo " ✅ Demo tasks ready in Conductor"
511+
echo ""
512+
echo "📚 Documentation: https://github.com/ryanmac/code-conductor"
513+
echo "🐛 Report issues: https://github.com/ryanmac/code-conductor/issues"
514+
echo ""
515+
echo -e "${GREEN}Happy orchestrating with Conductor! 🎼${NC}"
415516
fi
416-
echo " ✅ AI code-reviewer for all PRs"
417-
echo " ✅ Specialized roles: ${CONFIGURED_ROLES}"
418-
echo " ✅ Demo tasks ready to claim"
419-
echo ""
420-
echo "${YELLOW}Quick Start Commands:${NC}"
421-
echo " 📋 View tasks: ${GREEN}cat .conductor/workflow-state.json | jq '.available_tasks'${NC}"
422-
echo " 🤖 Start agent: ${GREEN}bash .conductor/scripts/bootstrap.sh dev${NC}"
423-
echo " 📝 Create task: ${GREEN}gh issue create -l 'conductor:task'${NC}"
424-
echo " 🔧 Adjust config: ${GREEN}$EDITOR .conductor/config.yaml${NC}"
425-
echo ""
426-
echo "${YELLOW}Your first PR will automatically get AI code reviews!${NC}"
427-
echo ""
428-
echo "📚 Documentation: https://github.com/ryanmac/code-conductor"
429-
echo "🐛 Report issues: https://github.com/ryanmac/code-conductor/issues"
430-
echo ""
431-
echo -e "${GREEN}Happy orchestrating! 🎼${NC}"

0 commit comments

Comments
 (0)