Laravel-4下的一个代码生成工具 Generators

https://github.com/JeffreyWay/Laravel-4-Generators

视频地址

http://tutsplus.s3.amazonaws.com/tutspremium/courses_%24folder%24/WhatsNewInLaravel4/9-Generators.mp4


修改

composer.json 文件,在

laravel/framework": "4.0.*


添加

"way/generators": "dev-master"


添加后内容如下


"laravel/framework": "4.0.*",
    "way/generators": "dev-master"
在命令行执行



composer update
执行完以后,在


app/config/app.php文件添加

找到'providers' => array(

在'Illuminate\Workbench\WorkbenchServiceProvider',后面添加


'Way\Generators\GeneratorsServiceProvider'
执行php artisan 多了下面几行内容


php artisan
generate
  generate:controller   Generate a new controller.
  generate:form         Dump form HTML for a model
  generate:migration    Generate a new migration.
  generate:model        Generate a new model.
  generate:resource     Generate a resource.
  generate:scaffold     Generate scaffolding for a resource
  generate:seed         Generate a seed file.
  generate:view         Generate a new view.


你可能感兴趣的:(laravel)