Seeder CI3 is a modern CLI-style development toolkit for CodeIgniter 3 inspired by Laravel Artisan and orangehill/iseed.
It provides migration management, database seeding, CRUD scaffolding, faker generation, route inspection, and development helpers while remaining fully compatible with traditional CodeIgniter 3 applications.
Seeder CI3 is designed for developers maintaining legacy systems who still want modern development workflows without migrating away from CodeIgniter 3.
Seeder CI3 includes:
- Database seeder generation from existing tables
- Migration generation and execution
- Migration rollback support
- CRUD scaffolding
- Model and controller generators
- Built-in faker generation
- Route listing utilities
- Post-migration hooks
- PostgreSQL-friendly helpers
- Lightweight response wrapper controller
- CLI-style development workflow for CodeIgniter 3
Install Seeder CI3 via Composer:
composer require virdiggg/seeder-ci3Create a controller new application/controllers/App_ci3.php for entry point:
<?php defined('BASEPATH') or exit('No direct script access allowed');
use Virdiggg\SeederCi3\MY_AppController;
class App_ci3 extends MY_AppController
{
public function __construct()
{
parent::__construct();
}
}Initialize Seeder CI3 inside your project:
php index.php app_ci3 initThe initialization command will automatically:
- Create
App_ci3.php - Create CLI bootstrap file
ci3 - Publish Seeder CI3 configuration
- Publish migration hooks
- Migrate legacy migration hooks automatically
Initialization may generate:
application/controllers/App_ci3.php
application/config/seeder.php
application/hooks/PostMigration.php
application/hooks/PreMigration.php
ci3Show available commands:
php ci3 helpCheck installed version:
php ci3 versionRun migrations:
php ci3 migrateRollback migrations:
php ci3 rollbackGenerate a model:
php ci3 make:model Admin/Users --r --c --m --soft-delete --fakerGenerate a seeder:
php ci3 make:seeder users --soft-deleteGenerate fake data:
php ci3 make:faker usersList application routes:
php ci3 router:list --postmanSeeder CI3 includes:
Virdiggg\SeederCi3\MY_ControllerA lightweight wrapper controller designed to simplify:
- JSON responses
- Pretty JSON formatting
- Shared view data
- HTML rendering
- View rendering
Example:
class Api extends MY_Controller
{
public function users()
{
return $this
->pretty(true)
->asJson([
'status' => true,
'message' => 'Success'
]);
}
}Seeder CI3 supports:
- Pre-migration hooks
- Post-migration hooks
- Legacy hook migration from old controller destructors
Useful for:
- Grant privilege automation
- Deployment workflows
- Logging
- Database synchronization
- Environment preparation
Seeder CI3 can generate fake datasets directly from existing table structures.
Example:
php ci3 make:faker usersSupports:
- Table-based faker generation
- Default fallback fields
- Faker-enabled model scaffolding
Seeder CI3 can inspect routes directly from terminal:
php ci3 router:listSupports:
- API route inspection
- Route auditing
- Endpoint discovery
- Postman export
Example:
php ci3 router:list --postmanCurrently optimized for:
application/controllers/api/*Generated files are stored in:
application/storage/Additional documentation:
Seeder CI3 aims to modernize the CodeIgniter 3 development experience without changing the framework's core architecture.
The goal is to provide practical developer tooling for long-term maintenance projects, enterprise systems, and legacy applications that still require fast and efficient workflows.