- What does codedungeon/laravel-craftsman actually do?
- Laravel Craftsman is a developer-time CLI package that extends the Artisan console with opinionated generators for common Laravel assets such as models, controllers, migrations, seeders, and factories. It wraps the native make:* commands and adds interactive prompts, sensible defaults, and customizable templates to reduce boilerplate. It is a scaffolding tool, not a runtime library, so it only writes source files that you would otherwise author by hand.
- How do I install Laravel Craftsman and should it be a dev dependency?
- Install it with Composer using an exact version pin under require-dev, for example composer require --dev codedungeon/laravel-craftsman. It should never be a production dependency because it exists purely to generate files during development. Confirm your deploy pipeline runs composer install --no-dev so the package is excluded from production builds.
- Which Laravel and PHP versions does Laravel Craftsman support?
- The last release was published in July 2020, which places the package in the Laravel 6/7 and PHP 7.x era. It predates Laravel 8's model-directory conventions, the typed PHP 8.1+ signatures in Laravel 9 and later, and several Symfony Console API changes. Treat any claimed support for newer versions as unverified until you test it on your own stack.
- Is Laravel Craftsman still maintained?
- No meaningful maintenance has occurred since the 2020 release, and the project has a single maintainer with no downstream dependents filing issues. Adopting it means accepting ownership of an effectively unmaintained tool. If you need it long term, plan to fork and pin it as an internal utility rather than rely on upstream updates.
- Does Laravel Craftsman work with Laravel 9, 10 or 11?
- It is unlikely to work out of the box on Laravel 9 and above because of framework API drift, PHP 8.1+ typed signatures, and changes in Symfony Console. Some generators may still run while others fail or emit outdated code patterns. Verify with a timeboxed spike on your exact Laravel and PHP versions before committing to it.
- How is Craftsman different from php artisan make:* and stub:publish?
- Native Artisan already generates models, controllers, migrations, and factories, and Laravel 9+ lets you publish and edit stubs directly. Craftsman's added value is interactive prompting, richer defaults, and its own template layer across many asset types. The honest way to decide is to diff native output against Craftsman output for a representative slice of resources and see whether the boilerplate savings are real.
- Are there alternatives to Laravel Craftsman for scaffolding?
- The most commonly recommended alternative is laravel-shift/blueprint, which is actively maintained, declarative via YAML schema definitions, and targets modern Laravel versions. You can also use native make:* commands combined with published stubs, or write small project-local Artisan commands for the generators you actually need. For most teams on current Laravel, native generators plus custom stubs win on maintenance economics.
- Can I customize the templates Craftsman generates?
- Yes, customizable templates are one of the package's stated features, allowing you to shape the generated models, controllers, and other assets to match your team's conventions. Because the package is unmaintained, any template customization you make should be committed alongside your project or in a fork. That keeps your customizations safe from version or dependency changes.
- Will Laravel Craftsman affect my production application?
- Runtime risk is effectively nil when the package is scoped to require-dev, since it adds no attack surface or performance overhead to deployed artifacts. The real risk is that it silently emits outdated code patterns such as pre-PHP-8 syntax or legacy controller idioms that later reach production. Run your linters, static analysis, and test suite over generated files to catch that early.
- How should I evaluate Laravel Craftsman before adopting it?
- Run a timeboxed spike: baseline native make:* output for a model with relationships, a resourceful controller, a migration, and a factory, then generate the same slice with Craftsman in a scratch branch and diff the results. Confirm it installs and runs cleanly on your current LTS and PHP version, and check whether a maintained fork or successor exists. If the delta is marginal, keep native generators and custom stubs; if it is substantial, fork and pin the package as an internal tool.