Navigation

Running DevCycles

From invocation to handoff. A practical guide to making DevCycles work for you.

Basic Execution

The simplest way to run a DevCycle is with the run command:

# Run a single DevCycle
lv devcycle run scaffold

# Run with feature context
lv devcycle run scaffold --feature user-authentication

# Preview actions without executing
lv devcycle run scaffold --dry-run

Execution Modes

Interactive Mode

The wizard walks you through each phase with confirmations:

lv devcycle run scaffold --wizard

# Output:
# ┌─────────────────────────────────────┐
# │ 🏗️  Scaffold DevCycle                │
# ├─────────────────────────────────────┤
# │ Feature: user-authentication        │
# │ Phase: Analyze                       │
# ├─────────────────────────────────────┤
# │ Ready to analyze requirements?       │
# │ [Y]es  [N]o  [S]kip                  │
# └─────────────────────────────────────┘

Headless Mode

For CI/CD pipelines, run without prompts:

# Non-interactive execution
lv devcycle run scaffold --no-interactive

# With automatic approval for checkpoints
lv devcycle run scaffold --auto-approve

# Fail on any warning (strict mode)
lv devcycle run scaffold --strict

Watch Mode

Monitor progress in real-time with the dashboard:

# Run with dashboard
lv devcycle run scaffold &
lv dashboard --watch

# Or in one command
lv devcycle run scaffold --dashboard

Chaining DevCycles

Run multiple DevCycles in sequence:

# Chain multiple cycles
lv devcycle run init scaffold test

# With shared context
lv devcycle run scaffold test validate --feature auth

# Stop on first failure
lv devcycle run scaffold test deploy --bail
💡

Dependency resolution

DevCycles automatically check prerequisites. Running deploywithout validate will prompt you to run validation first.

Phase Control

You can control which phases execute within a DevCycle:

# Run specific phases only
lv devcycle run scaffold --phases analyze,design

# Skip specific phases
lv devcycle run scaffold --skip-phases reflect

# Start from a specific phase
lv devcycle run scaffold --from-phase implement

# Stop at a specific phase
lv devcycle run scaffold --to-phase validate

Checkpoints

Understanding Checkpoints

Checkpoints are snapshots taken at phase boundaries. They include:

  • File state (modified, created, deleted files)
  • Git state (branch, commit, staged changes)
  • Execution logs and metrics
  • Environment configuration

Managing Checkpoints

# List all checkpoints
lv devcycle checkpoints

# Output:
# ID                              CYCLE     PHASE     DATE
# scaffold-analyze-2024-01-15     scaffold  analyze   2024-01-15 10:00
# scaffold-design-2024-01-15      scaffold  design    2024-01-15 10:30
# scaffold-implement-2024-01-15   scaffold  implement 2024-01-15 11:00

# View checkpoint details
lv devcycle checkpoints show scaffold-design-2024-01-15

# Restore to checkpoint
lv devcycle checkpoints restore scaffold-design-2024-01-15

Recovery Workflow

# If something goes wrong during implementation
lv devcycle checkpoints restore scaffold-design-2024-01-15

# Resume from where you left off
lv devcycle resume

# Or restart the cycle with different options
lv devcycle run scaffold --from-phase implement

Monitoring Execution

Dashboard

The terminal dashboard provides real-time visibility:

lv dashboard

# Features:
# - Current cycle and phase
# - Progress bars
# - Live log output
# - Resource usage
# - Error highlights

Logs

# Follow logs in real-time
lv logs --follow

# Filter by cycle
lv logs --cycle scaffold --since 1h

# Show only errors
lv logs --level error

# Export for analysis
lv logs --format json > execution-logs.json

CI/CD Integration

GitHub Actions Example

.github/workflows/devcycle.ymlyaml
name: DevCycle Validation

on:
  pull_request:
    branches: [main]

jobs:
  validate:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      
      - name: Setup Node.js
        uses: actions/setup-node@v4
        with:
          node-version: '20'
          
      - name: Install dependencies
        run: npm ci
        
      - name: Install Loaded Vibes
        run: npm install -g @loaded-vibes/cli
        
      - name: Run validation
        run: lv devcycle run validate --no-interactive --strict
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
          
      - name: Upload logs
        if: always()
        uses: actions/upload-artifact@v4
        with:
          name: devcycle-logs
          path: .loaded-vibes/logs/

Pre-commit Hook

.husky/pre-commitbash
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

# Run quick validation before commit
lv devcycle run validate --phases analyze --quick

Common Workflows

New Feature

# 1. Create feature branch
git checkout -b feature/user-auth

# 2. Run scaffold with feature context
lv devcycle run scaffold --feature user-auth

# 3. Implement and test
lv devcycle run features test --feature user-auth

# 4. Validate before PR
lv devcycle run validate review

# 5. Deploy to staging
lv devcycle run deploy --env staging

Bug Fix

# 1. Start debug cycle
lv devcycle run debug --issue 123

# 2. Implement fix
lv devcycle run features --bugfix

# 3. Test fix
lv devcycle run test validate

# 4. Review and merge
lv devcycle run review

Production Deployment

# 1. Full validation
lv devcycle run validate --strict

# 2. Security audit
lv devcycle run security

# 3. Performance check
lv devcycle run perf --baseline main

# 4. Deploy with approval
lv devcycle run deploy --env production --wizard

Troubleshooting

Cycle Failed

# Check what went wrong
lv logs --level error --cycle scaffold

# Get contextual help
lv hint error --detailed

# Restore and retry
lv devcycle checkpoints restore scaffold-design-2024-01-15
lv devcycle run scaffold --from-phase implement

Stuck in Phase

# Check current state
lv devcycle status --verbose

# Force phase transition
lv devcycle advance --force

# Reset cycle state
lv devcycle reset scaffold
⚠️

Force with caution

Using --force flags bypasses safety checks. Only use them when you understand the consequences.

Next Steps

Learn how to customize DevCycles for your specific needs, or explore troubleshooting for more recovery options.