How emirustaoglu/artisan works
Artisan is a PHP command-line toolkit for non-Laravel projects: developers invoke a generated project-level artisan proxy, which dispatches commands for database changes, scaffolding, and serving a development project. Migration and seed commands delegate to separate managers and database appliers; scaffolding and server dispatch are handled by the CLI class. The README documents view, controller, middleware, model, enum, migration, and seed generation. The CLI excerpt is partial, so undocumented command wiring and details of several generators are not inferred.
Main entry points: artisan.php Command dispatcher · MigrationManager.php Migration manager · Migration.php Migration applier · SeedsManager.php Seed manager
Components 14
Command interface
- Command dispatcher
src/artisan.php
Database operations
- Migration manager
src/databases/MigrationManager.php - Migration applier
src/databases/Migration.php - Seed manager
src/databases/SeedsManager.php - Seed applier
src/databases/Seeds.php
Setup and scaffolding
- Scaffold generators
src/artisan.php - Scaffold templates
src/temp - Proxy installer
src/install/FirstInstall.php
Other components
- Developer
- Project artisan proxy
- MySQL database
- Generated project files
- PHP development server
- Project public directory
Connections 15
- Developer → Project artisan proxy: runs command
- Project artisan proxy → Command dispatcher: calls
- Command dispatcher → Migration manager: dispatches migrate
- Migration manager → Migration applier: applies files
- Migration applier → MySQL database: executes SQL
- Command dispatcher → Seed manager: dispatches seeds
- Seed manager → Seed applier: applies files
- Seed applier → MySQL database: executes SQL
- Command dispatcher → Scaffold generators: dispatches make
- Scaffold generators → Scaffold templates: reads templates
- Scaffold generators → Generated project files: writes scaffolds
- Developer → Proxy installer: requests setup
- Proxy installer → Project artisan proxy: creates proxy
- Command dispatcher → PHP development server: starts server
- PHP development server → Project public directory: serves files