pirulug/crud-generator
Pirulug CRUD Generator scaffolds full Laravel CRUD interfaces from your existing models and database tables, generating controllers, routes, views, and forms so you can skip repetitive boilerplate and start building features faster.
Architecture fit. This is a dev-time scaffolding package (artisan generator commands producing controllers, models, API resources, validation rules, views, and layouts with Bootstrap/Tailwind stubs). It has no meaningful runtime footprint — the architectural coupling is to our conventions, not our request path. That makes it a low-risk fit for greenfield CRUD surfaces and a poor fit for domains with non-standard authorization,事件-driven workflows, or heavily customized UI.
Integration feasibility. High for Laravel 10–13 projects on PHP 8.2+. The v2.0.0 release materially improves adoptability: an Orchestra Testbench suite gives us something to point at in a review, correct exit codes (0 on success) make the generator CI-gateable, mergeConfigFrom plus discrete publish tags (crud-lang, presumably config/stubs) support reproducible provisioning, and Route Model Binding in generated controllers aligns output with current Laravel idioms rather than legacy findOrFail($id) patterns.
Technical risk.
toArray() API Resource field generation are convenience features that encode guesses. Generated field whitelists that are too permissive are a mass-assignment / data-exposure risk, and the generated code will be reviewed by humans who assume the generator got it right.Key questions.
--force and is it off by default?string named email vs. an actual email column), and is the inference overridable per-field?pint.json / formatting expectation documented, given the 2-space standard?Stack fit. Assumes PHP 8.2+, Laravel 10–13, and a Blade-based (or Inertia-adjacent) UI where Bootstrap or Tailwind stubs are acceptable. It is a scaffolder, so it fits best where our team has an agreed house style the stubs can be made to emit. If we have no such style, the package will manufacture one by accident.
Migration path. Treat v2.0.0 as a fresh adoption rather than an upgrade. Do not retrofit v2 onto a codebase with v1-generated artifacts in place — the Route Model Binding and indentation changes guarantee a mixed-style tree. If v1 is already in use somewhere, pin it, freeze regeneration, and migrate by hand-editing generated files or by regenerating into a scratch branch and diffing.
Compatibility gating.
Sequencing.
email/uuid/date/numeric columns plus an API Resource. Inspect every produced file. Confirm overwrite behavior, exit codes, Composer invocation, and publish-tag behavior.composer.json constraint, add a CI job that runs the test suite and a generation smoke test, and require human review of any generated file containing a field whitelist or validation rule.--force-free workflows.Maintenance. This is a dependency we inherit stubs from, not just a library. Every Laravel upgrade and every style decision becomes a stub-reconciliation task. The v2.0.0 indentation standardization is exactly the kind of cosmetic churn that generates diff noise across a whole repo — expect one such event per major version and plan for it.
Support. Single-maintainer risk is the dominant concern. Evidence for it: a major version with no migration guide, and a support matrix spanning EOL (10.x) through unreleased (13.x). Bilingual docs (EN/ES) suggest a solo or small maintainer investing in reach rather than depth. Mitigation is cheap — the package is small and the output is plain Laravel code we own — but we should be prepared to vendor/patch the generator ourselves rather than wait on upstream.
Scaling. Negligible. It runs at development time only; no runtime dependency in production, no added latency, no migration surface. Scaling concern is organizational: as more teams generate, divergent stub versions produce inconsistent codebases. Solve with a single pinned version and a shared stub set in a starter kit or internal package.
Failure modes.
toArray() field lists — produces working code with a security hole that passes review because it looks generated-and-therefore-correct.crud-lang / config if we publish repeatedly or across upgrades — vendored translations can silently shadow updated upstream strings.Ramp-up. Low technical ramp-up (artisan commands, predictable output) but non-trivial convention ramp-up: the team must agree on where generated code is acceptable, what must be added by hand (policies, form requests, tests), and who reviews field whitelists. Budget half a day of onboarding plus the stub-customization spike. Net expectation: meaningful time savings on the first CRUD surface, diminishing on the fifth as customization dominates — measure at the pilot rather than assume.
How can I help you explore Laravel packages today?