grahh / artisanplus
artisan 命令
v0.1.8
2018-09-26 13:57 UTC
Requires
- laravel/framework: 5.7.* | 5.6.*
README
artisan 命令包。
# 安装
- composer require grahh/artisanplus
- php artisan vendor:publish --provider="Grahh\Artisanplus\ArtisanplusProvider"
- php artisan config:cache
命令列表
php artisan make:repository {Model} // required argument Model
php artisan make:service {Name} {?--folder=} // required argument Name // optional parameter folder which will create additional namespace postfix after default config postfix and move file there
php artisan make:vo {Name} //creates Value Object
配置
- commands - 列出通过类名列表提到的命令
- namespaces - 列出默认命名空间
使用示例
make:repository
php artisan make:repository User --folder=One/Two //will create UserRepository.php in app_path(your/config/path/One/Two)
make:service
php artisan make:service Service //will create ServiceRepository.php in app_path(your/config/path/)
和
php artisan make:service One/Two/Service //will create ServiceRepository.php in app_path(your/config/path/One/Two/)
make:vo
php artisan:make Some //creates immutable Value Object Some.php