fabricio872/register-command
A small Laravel package that simplifies registering custom Artisan commands, letting you wire up command classes and keep your console tooling organized with minimal configuration.
Architecture fit — fundamental mismatch. Despite being scoped here as a "Laravel/PHP package," this is a Symfony bundle, not a Laravel package. Laravel consumes individual Symfony components (Console, HttpFoundation, Process) but not Symfony's bundle system — there is no Bundle class registration, no Extension/Configuration tree, no Kernel::registerBundles(). Any Laravel integration is therefore a port, not an install. The package's actual scope is narrow: a console command that creates a user record against a Doctrine entity, presumably using Symfony's password hasher and security stack. That narrow scope is the only thing that makes the mismatch tolerable.
Integration feasibility — the code is cheaper to reimplement than to adapt. A php artisan app:create-user command backed by Eloquent, Laravel's Hash facade, validation rules, and role assignment is roughly 60–120 lines and reuses the host app's existing model, policies, and validation. Vendoring the bundle would require a Doctrine ORM entity alongside Eloquent, a Symfony DI container bridge, and duplicated hashing configuration — more work than the port, with worse outcomes. Feasibility is high, but the artifact delivered is "informed by this package," not "this package."
Technical risk — elevated, driven by provenance rather than complexity. One star, zero dependents, one maintainer, a single release (2024-04-09). There is no third-party validation, no security review, and no evidence of use in production. The functional domain is also sensitive: authentication and credential handling executed from a terminal. Specific concerns to verify in source before any use:
Key questions for the maintainer / decision owner:
doctrine/orm, symfony/security-bundle, symfony/console)?--no-interaction) suitable for automation?Stack fit — poor as a dependency, adequate as a reference implementation. The correct posture is: read the source as a design reference, then build natively. Laravel teams should not add fabricio872/register-command to composer.json; the transitive symfony/security-bundle and doctrine/orm pulls would either fail to autoload usefully or introduce a second persistence paradigm into a codebase that is Eloquent-native.
Migration path. None in the data sense — this is an authoring tool, not a data layer, so there is no schema, no state, and no cutover to plan. The migration is conceptual:
Argument/Option definitions, Validator, Hash::make(), DB::transaction(), and secret()/ask() for masked password entry.Console/Kernel or command auto-discovery.If the target application genuinely is Symfony, adoption is conventional: composer require fabricio872/register-command, enable the bundle in bundles.php, publish/author the bundle config for entity class and role defaults, verify against the app's security firewall.
Compatibility. Expect Symfony 6.x/7.x and PHP 8.1+ as the supported envelope; that tells us nothing about Laravel 10/11 compatibility, which should be assumed absent until proven. Doctrine entity mapping is the hard blocker — it cannot be reconciled with an Eloquent User model without a mapping shim that no one should write.
Sequencing.
Maintenance — you inherit full ownership either way. With one release and one maintainer, expect no upstream fixes. That is acceptable only because the ported surface is small and lives in your own repository under your own test coverage. Do not take a runtime dependency on a single-release, single-star bundle in an authentication path.
Support. No community, no issue corpus, no documentation beyond a README. Internal documentation and a named owner are mandatory. The upside: the code is small enough that a mid-level engineer can fully understand it in an afternoon, so bus factor is manageable after the port.
Scaling. Effectively a non-issue. CLI user creation is low-frequency and human-gated. The one scaling-adjacent concern is automation: if the command is later used in provisioning or tenant onboarding, interactive prompts become a throughput and reliability problem, and the lack of idempotency (re-running creates duplicates or hard-fails) becomes a real operational defect.
Failure modes to design against:
Ramp-up. Low for the port: console command idioms are familiar to any PHP engineer and Laravel's Hash, Validator, and console helpers cover the entire feature set. The only ramp cost is for Laravel-only teams unfamiliar with Symfony bundle conventions — another reason to skip adoption entirely and treat this package as a spec, not a dependency.
How can I help you explore Laravel packages today?