Development Workflow
Daily Development
Section titled “Daily Development”Starting the Environment
Section titled “Starting the Environment”# Start backend containerscd backend./vendor/bin/sail up -d
# Start frontend dev servercd frontendpnpm dev
# Start documentation (optional)cd docspnpm devDevelopment URLs
Section titled “Development URLs”| Service | URL | Purpose |
|---|---|---|
| Backend API | http://localhost | Laravel API |
| Admin Panel | http://localhost/admin | FilamentPHP backoffice |
| Telescope | http://localhost/telescope | Debug dashboard |
| Swagger | http://localhost/api/documentation | API docs |
| Frontend | http://localhost:4321 | Astro website |
| Documentation | http://localhost:4322 | This site |
| Mailpit | http://localhost:8025 | Email testing |
Git Workflow
Section titled “Git Workflow”Branch Naming
Section titled “Branch Naming”feature/{issue-number}-{short-description}fix/{issue-number}-{short-description}refactor/{issue-number}-{short-description}Examples:
feature/123-add-payment-gatewayfix/456-booking-validation-error
Commit Messages
Section titled “Commit Messages”Format: #{issue-number} {descriptive-message}
# Goodgit commit -m "#123 Add user dashboard with profile management"git commit -m "#456 Fix booking validation for empty dates"
# Badgit commit -m "fix stuff"git commit -m "WIP"Slash Commands
Section titled “Slash Commands”Use Claude Code slash commands for common operations:
# Create a commit/commit "Add payment processing service"
# Create a pull request/pr-create
# Run PHPStan and fix errors/fix-phpstan
# Rebase onto master/rebase-masterCode Quality
Section titled “Code Quality”PHPStan (Level 6)
Section titled “PHPStan (Level 6)”All PHP code must pass PHPStan Level 6 analysis:
# Run PHPStan./vendor/bin/sail exec laravel.test ./vendor/bin/phpstan analyse
# Auto-fix with slash command/fix-phpstanLaravel Pint
Section titled “Laravel Pint”Format code with Laravel Pint:
./vendor/bin/sail pintTesting
Section titled “Testing”Run tests with Pest:
# All tests./vendor/bin/sail artisan test
# Specific test./vendor/bin/sail artisan test --filter=BookingTest
# With coverage./vendor/bin/sail artisan test --coverageWorking with Agents
Section titled “Working with Agents”Claude Code includes specialized agents for different tasks:
| Agent | Use For |
|---|---|
@laravel-core-agent | Models, migrations, controllers, services |
@filament-admin-agent | Admin resources, forms, tables, widgets |
@laravel-testing-agent | Pest tests, Pint formatting, coverage |
@laravel-debug-agent | Errors, logs, performance analysis |
Example: Creating a New Feature
Section titled “Example: Creating a New Feature”For a feature spanning multiple domains, invoke agents in parallel:
User: Create a Booking feature with admin panel and tests
├─ @laravel-core-agent: Model, migration, service├─ @filament-admin-agent: BookingResource└─ @laravel-testing-agent: Test suiteDatabase Operations
Section titled “Database Operations”Migrations
Section titled “Migrations”# Create migration./vendor/bin/sail artisan make:migration create_bookings_table
# Run migrations./vendor/bin/sail artisan migrate
# Rollback./vendor/bin/sail artisan migrate:rollback
# Fresh with seeders./vendor/bin/sail artisan migrate:fresh --seedSeeders
Section titled “Seeders”# Create seeder./vendor/bin/sail artisan make:seeder BookingSeeder
# Run seeders./vendor/bin/sail artisan db:seed
# Specific seeder./vendor/bin/sail artisan db:seed --class=BookingSeederTinker
Section titled “Tinker”Interactive PHP shell for debugging:
./vendor/bin/sail artisan tinker
# Example queries>>> User::count()>>> Booking::with('user')->first()>>> Product::where('active', true)->get()Queue Management
Section titled “Queue Management”Monitor Jobs
Section titled “Monitor Jobs”# Process jobs./vendor/bin/sail artisan queue:work
# List failed jobs./vendor/bin/sail artisan queue:failed
# Retry failed job./vendor/bin/sail artisan queue:retry {id}
# Clear failed jobs./vendor/bin/sail artisan queue:flushHorizon Dashboard
Section titled “Horizon Dashboard”Access Laravel Horizon at http://localhost/horizon for queue monitoring.
Debugging
Section titled “Debugging”Laravel Telescope
Section titled “Laravel Telescope”Access at http://localhost/telescope for:
- Request/response inspection
- Database queries
- Queue jobs
- Exceptions
- Logs
Laravel Boost MCP
Section titled “Laravel Boost MCP”Use the Laravel Boost MCP tools:
# Get last errormcp__laravel-boost__last-error
# Query databasemcp__laravel-boost__database-query "SELECT * FROM users LIMIT 5"
# Execute tinker codemcp__laravel-boost__tinker "User::count()"
# Search docsmcp__laravel-boost__search-docs ["queue jobs", "redis"]Pull Request Workflow
Section titled “Pull Request Workflow”Before Creating PR
Section titled “Before Creating PR”- Run tests:
./vendor/bin/sail artisan test - Run PHPStan:
/fix-phpstan - Format code:
./vendor/bin/sail pint - Update documentation if needed
Creating PR
Section titled “Creating PR”Use the slash command:
/pr-createThis will:
- Check for uncommitted changes
- Run PHPStan if PHP files changed
- Push branch to remote
- Create PR with template
PR Review
Section titled “PR Review”PRs require:
- Passing CI checks (tests, PHPStan)
- Code review approval
- Updated documentation (if applicable)